Xcode 2.2.1/Intel wrong install_name in gcc binary?
Xcode 2.2.1/Intel wrong install_name in gcc binary?
- Subject: Xcode 2.2.1/Intel wrong install_name in gcc binary?
- From: Karin Kosina <email@hidden>
- Date: Thu, 16 Feb 2006 23:45:41 +0100
Esteemed colleagues and fellow hackers,
Apologies in advance for bothering you with something that looks
suspiciously like a local problem, but I thought I'd drop you a
note to see if somebody else has run into this.
This is on the new Intel iMac, pristine system as shipped (Mac OS
10.4.5/8G1454). After installing the Developer Tools[*], I get the
following when trying to run gcc from the commandline:
$ gcc -o foo foo.c
dyld: Library not loaded: /usr/i686-apple-darwin8/lib/libgcc_s.1.dylib
Referenced from: /usr/bin/gcc
Reason: image not found
Trace/BPT trap
Inspecting the gcc binary reveals that it indeed has a dependency to
/usr/i686-apple-darwin8/lib/libgcc_s.1.dylib...
$ otool -L /usr/bin/gcc
/usr/bin/gcc:
/usr/i686-apple-darwin8/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 88.1.3)
...but no such file exists on my system.
Uninstalling and reinstalling the Xcode tools did not solve this
problem (I tried both the Xcode tools that came on the CD and the
disk image from the ADC website).
However, the installation seems to be ok apart from this - if I create
a symbolic link /usr/i686-apple-darwin8/lib/ pointing to /usr/lib (or
change the install_name of gcc to point to /usr/lib/libgcc_s.1.dylib,
though that's admittedly a scary thing to do ;)), everything works
fine:
$ sudo mkdir /usr/i686-apple-darwin8
# sudo ln -s /usr/lib /usr/i686-apple-darwin8/libfoo
$ gcc -o foo foo.cfoo
$ ./foo
I have a nagging feeling it's me doing something wrong - but whatever it
is, it is at least not mentioned in the "About Xcode Tools.pdf" file....
Any input most appreciated!
Kind regards, =/~ kyrah
[*] xcode_2.2.1_8g1165_018213632.dmg from the ADC website
--
t a v i v y e r g g r o n e b s r y c b r c b e g x r y r
g r a . u n e l x / / : c g g u
_______________________________________________
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