I recently downloaded Xcode 7 beta, and Xcode complains about some of my C libraries not being compiled into BitCode. How would I go about telling Clang to produce BitCode that is compatible with iOS? I've seen similar answers on stackoverflow, but I don't know if they apply to producing BitCode libraries for iOS.
Edit:
I am using the correct setting, -fembed-bitcode, but when I try to archive, I get the error: ld: warning: ignoring file XXXX/XXXX, file was built for archive which is not the architecture being linked (arm64). When I use -fembed-bitcode-marker, I can archive, but I get the error: full bitcode bundle could not be generated because XX/XX was built only with bitcode marker. The library must be generated from Xcode archive build with bitcode enabled.
Any ideas on what is going wrong? The library is compiling successfully, but it doesn't let me archive. I created a simple add function and made it into a library, and I get the same symptoms, so it is not the library I'm compiling.
Edit 2: You must build both the arm64 and armv7 versions using bitcode and lipo them together. Using bitcode doesn't take away the need for a fat library when archiving. source : Link