This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] 3.2: Fixup symbol versioning mistake on powerpc-linux-gnu


On Sun, Aug 04, 2002 at 09:02:02PM +0200, Franz Sirl wrote:
> Hi,
> 
> this turned out to be more difficult than I thought, but finally I had the 
> right idea on how to tackle that.
> 
> The patch changes the symbol versions in the shared libgcc for these sysmbols:
> 
> 	__divdi3	
> 	__udivdi3
> 	__moddi3
> 	__umoddi3
> 
> The change is to move the link-time reference from GLIBC_2.0 to GCC_3.0:
> 
> 	3.0, 3.1:		run+linktime @@GLIBC_2.0, runtime @GCC_3.0
> 	3.2+:		run+linktime @@GCC_3.0, runtime @GLIBC_2.0
> 
> This is to finally break the interaction between gcc and glibc on these 
> symbols.
> 
> Bootstrapped on i686-linux-gnu and powerpc-linux-gnu without regressions.
> 
> I will do a few more compatibility checks today+tomorrow, OK to commit to 
> mainline and 3.2 branch after that?
> 
> BTW, I noticed that the symbols in libgcc.a are only hidden by mklibgcc if 
> SHLIB_LINK is set, is this intentional? Doesn't that mean you have to build 
> gcc and glibc 2 times in a cross-compile environment to get a correct glibc 
> with no re-exported libgcc symbols?

I've been using this:

  Fix a visibility problem on libgcc, which led to PowerPC glibc build
  failures.  I need to take this up with the GCC developers at next
  opportunity; it may not be correct for all platforms (but is for all
  of our platforms).
    - djacobowitz

--- gcc-3.1/gcc/mklibgcc.in.orig	Wed Jul 24 12:23:59 2002
+++ gcc-3.1/gcc/mklibgcc.in	Wed Jul 24 12:24:26 2002
@@ -279,7 +279,7 @@
 
   libgcc_a_objs="$libgcc_objs $libgcc_st_objs"
 
-  if [ "@libgcc_visibility@" = yes -a "$SHLIB_LINK" ]; then
+  if [ "@libgcc_visibility@" = yes ]; then
     libgcc_a_objs=
     echo ""
     for o in $libgcc_objs $libgcc_st_objs; do


-- 
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]