Re: Link errors
Re: Link errors
- Subject: Re: Link errors
- From: Eric Albert <email@hidden>
- Date: Wed, 12 Apr 2006 23:14:01 -0700
On Apr 12, 2006, at 2:49 PM, Chris Espinosa wrote: On Apr 12, 2006, at 2:40 PM, Steve Mills wrote: Today, Xcode started failing to link a project that has worked in the past. I see lots of these in the build transcript:
symbol _acosl used from dynamic library /Developer/SDKs/MacOSX10.3.9.sdk/usr/lib/gcc/powerpc-apple-darwin8/4.0.1/libstdc++.dylib(single module) not from earlier dynamic library /usr/lib/libSystem.B.dylib(ld64.o) symbol _tanl used from dynamic library /Developer/SDKs/MacOSX10.3.9.sdk/usr/lib/gcc/powerpc-apple-darwin8/4.0.1/libstdc++.dylib(single module) not from earlier dynamic library /usr/lib/libSystem.B.dylib(ld64.o)
The failed link is the ppc build of a Universal Binary. The ppc build uses the 10.3.9.sdk and deployment target is 10.3. Those errors look to me like one thing using libstdc++.dylib from the 10.3.9.sdk and another thing is using libSystem.B.dylib from /usr/lib. I don't understand what that means. The main project and all subprojects use the same sdk and deployment target settings, and all libraries and frameworks were added from the /usr/lib or /System/Library/Frameworks/ directories, NOT from the .sdk directories. I just double-checked these things and didn't notice anything using the wrong lib/framework. Any ideas? The Debug config builds fine (but probably doesn't complain because ZeroLink is on).
It looks like one of your executables was built for ppc64 along with ppc and i386. You probably didn't want that.
I think Chris suggested that due to the 'ld64' above. ld64 is the linker for ppc64. But the message above references a module in Libsystem, not a binary. And there is a module called ld64.o in Libsystem, as you can see by doing nm /usr/lib/libSystem.B.dylib | grep ld64 on any Panther or Tiger system. ld64.o comes from ld64.c in Libm and contains implementations of long double APIs which use doubles instead of long double for folks who build with -mlong-double-64 to get 64-bit long doubles (which we don't recommend).
Instead, something here is causing you to pull in the system's Libsystem rather than the SDK's. One way to try to find it would be to look through the entire build transcript for the first reference to /usr/lib/libSystem.B.dylib and see if that shows you anything. Another option is to open your real project file -- the project.pbxproj inside the package that is your project -- in a text editor and look for any explicit references to /usr/lib/libSystem.B.dylib. Those should theoretically all get turned into SDK references automatically, but it sounds like you might've found a case where that doesn't happen....
Hope this helps, Eric
|
_______________________________________________
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