[PATCH] Fix PR other/7956
Eric Botcazou
ebotcazou@libertysurf.fr
Tue Dec 2 11:56:00 GMT 2003
Hi,
This is an old problem related to multilib on SPARC/Solaris 7, 8 and 9. The
compiler is always built as a multiarch compiler on these platforms, and by
default, as a multilib compiler. Now, you may want (or need) not to build
both flavors of the libraries by passing --disable-multilib to the top-level
configure script.
So, in this case, you end up with a multiarch but not multilib compiler. This
means that you can compile but not link, the error issued in the latter case
being a bit cryptic:
ld: fatal: file /usr/lib/sparcv9/values-Xa.o: cannot open file: No such file
or directory
ld: fatal: file /var/tmp//ccKb4eqM.o: wrong machine class
ld: fatal: File processing errors. No output written to a.out
collect2: ld returned 1 exit status
The attached patch turns the error message into:
gcc: does not support multilib
Compiled on sparc64-sun-solaris2.9 and sparc-sun-solaris2.8. Ok for mainline?
2003-12-02 Eric Botcazou <ebotcazou@libertysurf.fr>
PR other/7956
* genmultilib: New variable disable_multilib. Set it to 'yes'
if enable_multilib was set to 'no'. Emit DISABLE_MULTILIB
if disable_multilib was set to 'yes'.
* gcc.c: Include multilib.h before tm.h.
* config/sparc/sol2-bi.h (LINK_ARCH_SPEC): Emit an error
message for multiarch options if DISABLE_MULTILIB is set.
--
Eric Botcazou
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pr7956.diff
Type: text/x-diff
Size: 2611 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20031202/b4362fcb/attachment.bin>
More information about the Gcc-patches
mailing list