Multi-platform orientation in iPhone SDK 4

I have an iPhone SDK project that is supposed to create a static library for a simulator and an ARM processor, and then combine them into a universal library.

So far I have used the iPhone SDK 3+ and achieved this by creating a separate goal for each, one simulator and one ARM, and then creating a third goal that combines them using a shell script. The deployment / assembly target parameters for each of the component targets are set in their respective architectures, etc. Also, the iPhone SDK 3+ allowed me to select “Base SDK” from the drop-down menu in the upper left corner of the main Xcode window.

Everything worked great - then I upgraded to SDK 4.

Now there is no “Base SDK" list in the drop-down menu in the upper left corner. In addition, the compiler completely ignores deployment targets. Despite the fact that “iPhone Device” is installed for one of the goals and “iPhone Simulator” is set for the other, they are still built in the same way as in the drop-down menu.

In the event that I was not clear enough, here is the abusive insult that we all know and love about:

offending menu

Once again, in SDK 3, everything worked perfectly. Now in SDK 4, if it is installed on "Device", I get two libraries created for ARM. If it is installed in the simulator, I get two libraries created for the simulator.

Does anyone know of a workaround for this bullhonkey?

Many thanks.

UPDATE: "xcodebuild" , .

, XCode script, xcodebuild :

xcodebuild -target device-target -configuration Debug
xcodebuild -target sim-target -configuration Debug

, .

+3
3

, Apple, , XCode . , Beta SDK GM/public SDK, . , -.

, Script , . Script bag-o-tricks. XCode Project BaseSDK iPhone Device 4.0 SDK. Script :

xcodebuild -parallelizeTargets -configuration Debug -sdk iphoneos4.0 -target StaticLibs
xcodebuild -parallelizeTargets -configuration Debug -sdk iphonesimulator4.0 -target StaticLibs
xcodebuild -parallelizeTargets -configuration Release -sdk iphoneos4.0 -target StaticLibs
xcodebuild -parallelizeTargets -configuration Release -sdk iphonesimulator4.0 -target StaticLibs
mkdir -p build/Debug-dist build/Release-dist
lipo build/Debug-iphoneos/libfoo.a build/Debug-iphonesimulator/libfoo.a -create -output build/Debug-dist/libfoo.a
lipo build/Release-iphoneos/libfoo.a build/Release-iphonesimulator/libfoo.a -create -output build/Release-dist/libfoo.a

, , . Script for thing in ${LIST_OF_STUFF}; do ..., , SDK.

Core-Plot, SDK . , / GCC_VERSION SDKSettings.plist , .

+3

, " SDK" SDK, "iPhone OS Deployment Target" ( ) , .

, , iPhone OS 3.1.2 , " SDK" 4.0 " iPhone OS" 3.1.2.

+1

On iPhone sdk 4.0, the apple removed every version of iOS below 3.2. If you create for iPhone, it will be automatically created for version 4.0, and if you create for iPad, it will be compiled as 3.2.

0
source

Source: https://habr.com/ru/post/1752698/


All Articles