patches/gcc/3.3.1/sh-spec.patch
author "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Sat Feb 24 11:00:05 2007 +0000 (2007-02-24)
changeset 1 eeea35fbf182
permissions -rw-r--r--
Add the full crosstool-NG sources to the new repository of its own.
You might just say: 'Yeah! crosstool-NG's got its own repo!".
Unfortunately, that's because the previous repo got damaged beyond repair and I had no backup.
That means I'm putting backups in place in the afternoon.
That also means we've lost history... :-(
     1 See http://gcc.gnu.org/PR11902
     2 
     3 Part of fix for abort on line
     4   assert (info[DT_RPATH] == NULL);
     5 in glibc-2.3.2's ld.so, which makes all dynamically-linked
     6 programs crash.
     7 
     8 Message-Id: <200308020452.h724q0n01509@r-rr.iij4u.or.jp>
     9 To: dank@kegel.com
    10 Cc: kkojima@rr.iij4u.or.jp
    11 Subject: Re: Writing PIC version of __udivsi3_i4?
    12 In-Reply-To: Your message of "Fri, 01 Aug 2003 21:15:27 -0700"
    13 	<3F2B3ADF.6030206@kegel.com>
    14 References: <3F2B3ADF.6030206@kegel.com>
    15 Date: Sat, 02 Aug 2003 13:58:05 +0900
    16 From: kaz Kojima <kkojima@rr.iij4u.or.jp>
    17 
    18 Dan Kegel <dank@kegel.com> wrote:
    19 > It seems it might be from gcc's spec file:
    20 > 
    21 > *subtarget_link_spec:
    22 > %{shared:-shared}    %{!static:      %{rdynamic:-export-dynamic}      %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}      %{!rpath:-rpath /lib}}    %{static:-static}
    23 > 
    24 > as the only place -rpath showed up was in the output of gcc -v as it
    25 > was linking libc.so.
    26 > 
    27 > Well, that's a clue, anyway!  Guess I'll dig through the spec files
    28 > tomorrow to see if I can figure it out some more.
    29 
    30 I've grepped gcc/config/*/*.h and found only SH and old libc1 stuffs
    31 of i386/alpha include %{!rpath:-rpath ... in 3.3 release and the
    32 current CVS. And my sh-gcc's specs doesn't have this :-(
    33 It would be the Right Thing to remove this stuff simply. How about
    34 the gcc patch below?
    35 
    36 Regards,
    37 	kaz
    38 --
    39 --- gcc-3.3/gcc/config/sh/linux.h.orig	Sat Aug  2 13:20:57 2003
    40 +++ gcc-3.3/gcc/config/sh/linux.h	Sat Aug  2 13:22:42 2003
    41 @@ -48,8 +48,7 @@ do { \
    42    "%{shared:-shared} \
    43     %{!static: \
    44       %{rdynamic:-export-dynamic} \
    45 -     %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2} \
    46 -     %{!rpath:-rpath /lib}} \
    47 +     %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \
    48     %{static:-static}"
    49  
    50  /* The GNU C++ standard library requires that these macros be defined.  */
    51 
    52