Xcode: Converting Static Lib to Framework

Xcode: Converting Static Lib to Framework

If your static library contains hundreds of public header files and few hundreds compile sources this could be a tedious task.

My initial thought on how to do this is to bring up two editors with Build Phases side by side and then select all files in Compile Sources from the static lib and just drag-n-drop it to my framework Compile Sources, which resulted with duplicated files in the project navigator.

Here's magical approach:

  1. Select all files in static lib
  2. Press Cmd + Shift + J
  3. Drag-n-drop selected files from Project Navigator to your build phase of your framework target