This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[3.4/3.5 PATCH/RFA] Fix SH bootstrap failure (PR 15120)
- From: Kaz Kojima <kkojima at rr dot iij4u dot or dot jp>
- To: gcc-patches at gcc dot gnu dot org
- Cc: Mark Mitchell <mark at codesourcery dot com>, joern dot rennecke at superh dot com, aoliva at redhat dot com
- Date: Sun, 25 Apr 2004 09:21:55 +0900 (JST)
- Subject: [3.4/3.5 PATCH/RFA] Fix SH bootstrap failure (PR 15120)
Hi,
sh4-unknown-linux-gnu has a problem (PR 15100) on 3.4/3.5 in bootstrap
which -fno-unit-at-a-time gets rid of, but even with that workaround,
3.4/3.5 failed on native sh4-unknown-linux-gnu with the newer ld in
building libstdc++-v3/testsuite/abi_check:
/usr/gnu/sh4-unknown-linux-gnu/bin/ld: abi_check: hidden symbol `__sdivsi3_i4' in /mnt/hda3/ldroot/dodes/sh-gcc340/gcc/libgcc.a(_sdivsi3_i4.oS) is referenced by DSO
collect2: ld returned 1 exit status
The attached patch fixes it. It's tested with bootstrap on i686-linux
and sh4-unknown-linux-gnu without regressions. The up-stream libtool.m4
in the libtool cvs has set lt_cv_deplibs_check_method to pass_all for
sh*-linux* already and the similar patch was used by sh-linux folks at
least 2 years as a local patch. It was once proposed to gcc-patches and
then forgotten. Maybe my bad.
One concern is if it's appropriate also for sh64. I think it's ok for
the current FSF gcc & binutils combination and sh64-linux guys usually
use more patched sources from SuperH which has no problem for this change.
Since the above error doesn't happen to 3.3.3, it's a regression from
3.3. I've confirmed 3.4 version of this patch with bootstrap/regtest
on i686-linux and sh4-unknown-linux-gnu, though the latter target needs
-fno-unit-at-a-time to bootstrap at the moment.
Is it ok for mainline and 3.4-branch?
Regards,
kaz
--
2004-04-24 Kaz Kojima <kkojima@gcc.gnu.org>
* libtool.m4 (lt_cv_deplibs_check_method): Use pass_all on sh*.
* */configure: Rebuilt.
diff -u3prN ORIG/gcc/libtool.m4 LOCAL/gcc/libtool.m4
--- ORIG/gcc/libtool.m4 Thu Nov 20 08:57:06 2003
+++ LOCAL/gcc/libtool.m4 Sat Apr 24 09:53:36 2004
@@ -680,7 +680,7 @@ irix5* | irix6*)
# This must be Linux ELF.
linux-gnu*)
case $host_cpu in
- alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* )
+ alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* | sh* )
lt_cv_deplibs_check_method=pass_all ;;
*)
# glibc up to 2.1.1 does not perform some relocations on ARM