Committed, CRIS: config/cris.h config/linux.h: Don't --gc-sections if -r.
Hans-Peter Nilsson
hans-peter.nilsson@axis.com
Tue Jul 16 19:31:00 GMT 2002
Should have sent this long ago; I didn't because trunk
cris-axis-linux-gnu never finished (presumably binutils
problems, preventing trunk to build libstdc++-v3; later). The
linux.h change is a show-stopper for cris-axis-linux-gnu on 3.1,
so I applied it there. Without it, cris-axis-linux-gnu doesn't
build due to that warped construct that uses -r in the process
of hiding symbols while building libgcc (on the 3.1-branch). I
committed the linux.h change to main trunk *and* 3.1-branch.
The cris.h change is committed on the trunk only.
Admittedly, using --gc-sections like this might expose other
problems. Later.
* config/cris/linux.h (CRIS_LINK_SUBTARGET_SPEC): Don't
--gc-sections if -r.
* config/cris/cris.h: Ditto.
Index: linux.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/cris/linux.h,v
retrieving revision 1.3.2.2
diff -p -c -r1.3.2.2 linux.h
*** linux.h 13 Apr 2002 20:18:34 -0000 1.3.2.2
--- linux.h 5 Jul 2002 20:24:21 -0000
*************** Boston, MA 02111-1307, USA. */
*** 96,102 ****
%{shared} %{static}\
%{symbolic:-Bdynamic} %{shlib:-Bdynamic} %{static:-Bstatic}\
%{!shared:%{!static:%{rdynamic:-export-dynamic}}}\
! %{O2|O3: --gc-sections}"
/* Node: Sections */
--- 96,102 ----
%{shared} %{static}\
%{symbolic:-Bdynamic} %{shlib:-Bdynamic} %{static:-Bstatic}\
%{!shared:%{!static:%{rdynamic:-export-dynamic}}}\
! %{!r:%{O2|O3: --gc-sections}}"
/* Node: Sections */
Index: cris.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/cris/cris.h,v
retrieving revision 1.25.2.4
diff -p -c -r1.25.2.4 cris.h
*** cris.h 2 Jul 2002 14:08:00 -0000 1.25.2.4
--- cris.h 5 Jul 2002 20:32:08 -0000
*************** extern const char *cris_elinux_stacksize
*** 211,217 ****
#define CRIS_LINK_SUBTARGET_SPEC \
"-mcriself\
%{sim2:%{!T*:-Tdata 0x4000000 -Tbss 0x8000000}}\
! %{O2|O3: --gc-sections}"
/* Which library to get. The only difference from the default is to get
libsc.a if -sim is given to the driver. Repeat -lc -lsysX
--- 211,217 ----
#define CRIS_LINK_SUBTARGET_SPEC \
"-mcriself\
%{sim2:%{!T*:-Tdata 0x4000000 -Tbss 0x8000000}}\
! %{!r:%{O2|O3: --gc-sections}}"
/* Which library to get. The only difference from the default is to get
libsc.a if -sim is given to the driver. Repeat -lc -lsysX
brgds, H-P
More information about the Gcc-patches
mailing list