OSX library: unsupported file format
OSX library: unsupported file format
- Subject: OSX library: unsupported file format
- From: Nathan Sims <email@hidden>
- Date: Thu, 26 May 2011 12:55:48 -0700
I'm having trouble linking with a static C library I built in Xcode 3.2.6 on an iMac 10.6.7.
$ cc -g -o test test.c build/Debug/libTestOSX.a
ld: warning: in build/Debug/libTestOSX.a, file was built for unsupported file format which is not the architecture being linked (x86_64)
$ file build/Debug/libTestOSX.a
build/Debug/libTestOSX.a: current ar archive random library
In Xcode, the settings for the library are:
ARCHS = $(ARCHS_STANDARD_32_64_BIT)
SDKROOT = macosx
ONLY_ACTIVE_ARCH = NO
VALID_ARCHS = i386 ppc ppc64 ppc7400 ppc970 x86_64
When I build with these settings in Xcode, the Build log says:
Libtool build/Debug/libCloudServerOSX.a normal i386
What am I doing wrong?
Is it possible to build a 'universal' library that includes both x86_64 and i386 architectures? Right now I have to build specifically for each of those target types.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden