kstenerud / iOS-Universal-Framework

An XCode project template to build universal frameworks (arm7, arm7s, and simulator) for iOS / iPhone.
2.95k stars 473 forks source link

'arm/types.h' file not found #72

Closed tommy31 closed 1 year ago

tommy31 commented 11 years ago

Hi, when i try to compil my framework using your framework i get this error :

/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/usr/include/machine/types.h:37:10: fatal error: 'arm/types.h' file not found

I try to compile only for armv6 arch.

ghost commented 11 years ago

Have this issue also trying to compile for armv6. Works fine for armv7, but after adding support for armv6 get the same error (except my file is "arm/_types.h")

danh-rm commented 11 years ago

Have previously seen this error and had to create a new framework and copy my files across. I believe it's the case that new frameworks build ARM6 and 7 by default, anyway.

tommy31 commented 11 years ago

I try to create a new framework and copy my files in. I had the same issue. But maybe framework compilation is ok and i can use it ?

edit: error only happened when i create a fake framework !

tommy31 commented 11 years ago

I found the solution with this tutorial : http://db-in.com/blog/2011/07/universal-framework-iphone-ios-2-0/

Maybe this can help you ChristopherLord ;)

IMPORTANT: Since the Xcode 4.x the architectures armv6 has no longer support. So, to create a real Universal Framework we must make a small “hack”:

After change the settings above close the Xcode, find the .xcodeproj (the project file) in Finder and then “Show Package Contents”. Open the file “project.pbxproj” into a text editor. Delete all the lines with VALID_ARCHS = “$(ARCHS_STANDARD_32_BIT)”.

vecter commented 11 years ago

I'm coming across the same error now, any ideas?

@tommy31 Did that actually work? I find when I do that "hack", all it does is remove armv6 from the build.

ghost commented 11 years ago

Nah, we came up with a solution unique to our needs. We decided to drop support for armv6, however allow it to be linked on armv6 devices, for older apps to build with it but not use it (as I say, unique to our needs).

We built our own armv6-only static library the normal way, with our public header with stub implementations of the header. We then took the X.framework/X and merged it with our armv6stub.a at the end of our build process.

codifilo commented 11 years ago

I had this issue and I solved it by setting in the target Build Settings: Architectures = armv6 armv7 i386 (it's important to remove the $(ARCHS_STANDARD_32_BIT) crap) Valid Architectures = armv6 armv7 i386