Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to make xcode automatically choosing the correct platform lib(.a)

I made two version of my library to fit different platform as device and simulator

How to make xcode automatically choosing the correct platform lib(.a) with the config of the target's "Base SDK" ?

and By using the same header files. I know Admob could do this without any modify but configuring the Base SDK.

like image 552
xhan Avatar asked Jun 01 '26 21:06

xhan


1 Answers

You can use lipo to merge the .a file from both platforms into one .a file. Once you do that, it will automatically choose the current platform's binary. See here for instructions:

http://dev.byteclub.com/blog/1-iphone-sdk/48-how-to-almost-create-your-own-iphone-os-framework

like image 182
Ken Aspeslagh Avatar answered Jun 03 '26 10:06

Ken Aspeslagh