Re: thin linking: "file is not of required architecture"
Re: thin linking: "file is not of required architecture"
- Subject: Re: thin linking: "file is not of required architecture"
- From: Philip Hölzenspies <email@hidden>
- Date: Thu, 10 Apr 2008 13:30:35 +0100
On Apr 10, 2008, at 11:53 AM, Alastair Houghton wrote:
Sorry, quite right, I hadn't spotted the "-o".
Mind-you, that begs the question, what exactly are you trying to
link here? The two things on the right use the extension ".so", so
I'm guessing that they are dylibs (.dylib is the standard extension
on Mac OS X). It would never even occur to me to try to specify two
dylibs and ask the linker to output an ordinary object file, and if
I did that, I would expect it to give an error since it doesn't
really have anything to link.
That the error message doesn't seem helpful is obviously less than
ideal.
Dear Alestair, all,
This might be a case of an over-isolated example. It comes from trying
to link a binary. It would be too much fuss to give the entire
example, but the error came from a command like:
$ ld -arch i386 -o application lib1.so lib2.so lib3.so foo.o bar.o
and the errors where about the .so files. If you look closely, btw,
you see that ld just gives *warnings*. It's only when linking a binary
(actually, anything without the -r option) that this results in a
bunch of "symbol XXX not found" errors (where the symbols are in the
so files that ld can't properly determine the architecture for).
Mind you, all the so files I mention here were compiled with this
exact same installation, i.e. with the same gcc/ld that fails for my
binary.
Regards,
Philip
_______________________________________________
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