1 diff -urN gcc-2.95.1.orig/gcc/Makefile.in gcc-2.95.1/gcc/Makefile.in
2 --- gcc-2.95.1.orig/gcc/Makefile.in Fri Aug 13 09:46:55 1999
3 +++ gcc-2.95.1/gcc/Makefile.in Thu Aug 19 13:25:21 1999
5 # libgcc1-test target (must also be overridable for a target)
6 LIBGCC1_TEST = libgcc1-test
8 +# The libgcc symbol versioning map.
11 # List of extra executables that should be compiled for this target machine
12 # that are used for compiling from source code to object code.
13 # The rules for compiling them should be in the t-* file for the machine.
15 # Note that we can compile enquire using the cross-compiler just built,
16 # although we can't run it on this machine.
17 all.cross: native gcc-cross specs stmp-headers $(STMP_FIXPROTO) $(LIBGCC) \
18 - $(LIBGCC1_TEST) $(EXTRA_PARTS) lang.all.cross doc
19 + $(LIBGCC_MAP) $(LIBGCC1_TEST) $(EXTRA_PARTS) lang.all.cross doc
20 # This is what to compile if making gcc with a cross-compiler.
21 all.build: native xgcc$(exeext) xcpp$(exeext) $(EXTRA_PARTS) lang.all.build
22 # This is what must be made before installing GCC and converting libraries.
23 start.encap: native xgcc$(exeext) xcpp$(exeext) specs $(LIBGCC1) \
24 xlimits.h lang.start.encap
25 # These can't be made until after GCC can run.
26 -rest.encap: stmp-headers $(STMP_FIXPROTO) $(LIBGCC) $(EXTRA_PARTS) lang.rest.encap
27 +rest.encap: stmp-headers $(STMP_FIXPROTO) $(LIBGCC) $(LIBGCC_MAP) \
28 + $(EXTRA_PARTS) lang.rest.encap
29 # This is what is made with the host's compiler
30 # whether making a cross compiler or not.
31 native: config.status auto-host.h cpp$(exeext) intl.all $(LANGUAGES) \
34 # On the target machine, finish building a cross compiler.
35 # This does the things that can't be done on the host machine.
36 -rest.cross: $(LIBGCC) specs
37 +rest.cross: $(LIBGCC) $(LIBGCC_MAP) specs
39 # Verify that it works to compile and link libgcc1-test.
40 # If it does, then there are sufficient replacements for libgcc1.a.
42 # Using unprotoize.c is not quite right in the first place,
43 # but what better way is there?
44 -rm -f libgcc.a libgcc1.a libgcc1-asm.a libgcc2.a libgcc2.ready
46 + -rm -f libgcc1.null libgcc.map
49 -if [ -f md.pre-cpp ]; then \
50 @@ -2526,6 +2530,12 @@
51 $(INSTALL_DATA) specs $(libsubdir)/specs; \
52 chmod a-x $(libsubdir)/specs; \
54 +# Install libgcc.map if it exists.
55 + -if [ -n "$(LIBGCC_MAP)" -a -f libgcc.map ] ; then \
56 + rm -f $(libsubdir)/libgcc.map; \
57 + $(INSTALL_DATA) libgcc.map $(libsubdir)/libgcc.map; \
58 + chmod a-x $(libsubdir)/libgcc.map; \
60 # Install protoize if it was compiled.
61 -if [ -f protoize$(exeext) ]; \
63 @@ -3041,6 +3051,10 @@
64 -if [ -f collect-ld$(exeext) ] ; then $(LN_S) ../collect-ld$(exeext) stage1 ; else true ; fi
65 -rm -f stage1/libgcc.a
67 + -if [ -n "$(LIBGCC_MAP)" -a -f libgcc.map ] ; then \
68 + rm -f stage1/libgcc.map; \
69 + cp libgcc.map stage1; \
71 -if $(RANLIB_TEST_FOR_TARGET) ; then \
72 $(RANLIB_FOR_TARGET) stage1/libgcc.a; \
74 @@ -3065,6 +3079,10 @@
75 -if [ -f collect-ld ] ; then $(LN_S) ../collect-ld$(exeext) stage2 ; else true ; fi
76 -rm -f stage2/libgcc.a
78 + -if [ -n "$(LIBGCC_MAP)" -a -f libgcc.map ] ; then \
79 + rm -f stage2/libgcc.map; \
80 + cp libgcc.map stage2; \
82 -if $(RANLIB_TEST_FOR_TARGET) ; then \
83 $(RANLIB_FOR_TARGET) stage2/libgcc.a; \
85 @@ -3089,6 +3107,10 @@
86 -if [ -f collect-ld$(exeext) ] ; then $(LN_S) ../collect-ld$(exeext) stage3 ; else true ; fi
87 -rm -f stage3/libgcc.a
89 + -if [ -n "$(LIBGCC_MAP)" -a -f libgcc.map ] ; then \
90 + rm -f stage3/libgcc.map; \
91 + cp libgcc.map stage3; \
93 -if $(RANLIB_TEST_FOR_TARGET) ; then \
94 $(RANLIB_FOR_TARGET) stage3/libgcc.a; \
96 @@ -3113,6 +3135,10 @@
97 -if [ -f collect-ld$(exeext) ] ; then $(LN_S) ../collect-ld$(exeext) stage4 ; else true ; fi
98 -rm -f stage4/libgcc.a
100 + -if [ -n "$(LIBGCC_MAP)" -a -f libgcc.map ] ; then \
101 + rm -f stage4/libgcc.map; \
102 + cp libgcc.map stage4; \
104 -if $(RANLIB_TEST_FOR_TARGET) ; then \
105 $(RANLIB_FOR_TARGET) stage4/libgcc.a; \
107 @@ -3196,3 +3222,9 @@
108 echo "#endif" >> t-float.h-cross
109 mv t-float.h-cross float.h-cross
111 +# Rule to generate the libgcc symbol versioning map.
113 + echo "GCC.INTERNAL {" > $@
114 + echo " local:" >> $@
115 + $(EXTRACT_LIBGCC) >> $@
117 diff -urN gcc-2.95.1.orig/gcc/config/i386/i386.md gcc-2.95.1/gcc/config/i386/i386.md
118 --- gcc-2.95.1.orig/gcc/config/i386/i386.md Sun Apr 25 13:43:46 1999
119 +++ gcc-2.95.1/gcc/config/i386/i386.md Thu Aug 19 13:25:21 1999
120 @@ -1345,7 +1345,8 @@
121 else if ((reload_in_progress | reload_completed) == 0
122 && GET_CODE (operands[0]) != MEM
123 && GET_CODE (operands[1]) == CONST_DOUBLE
124 - && !standard_80387_constant_p (operands[1]))
125 + && ((flag_pic && flag_omit_frame_pointer)
126 + || ! standard_80387_constant_p (operands[1])))
128 operands[1] = validize_mem (force_const_mem (SFmode, operands[1]));
130 @@ -1473,7 +1474,8 @@
131 else if ((reload_in_progress | reload_completed) == 0
132 && GET_CODE (operands[0]) != MEM
133 && GET_CODE (operands[1]) == CONST_DOUBLE
134 - && !standard_80387_constant_p (operands[1]))
135 + && ((flag_pic && flag_omit_frame_pointer)
136 + || ! standard_80387_constant_p (operands[1])))
138 operands[1] = validize_mem (force_const_mem (DFmode, operands[1]));
140 @@ -1601,7 +1603,8 @@
141 else if ((reload_in_progress | reload_completed) == 0
142 && GET_CODE (operands[0]) != MEM
143 && GET_CODE (operands[1]) == CONST_DOUBLE
144 - && !standard_80387_constant_p (operands[1]))
145 + && ((flag_pic && flag_omit_frame_pointer)
146 + || ! standard_80387_constant_p (operands[1])))
148 operands[1] = validize_mem (force_const_mem (XFmode, operands[1]));
150 diff -urN gcc-2.95.1.orig/gcc/config/linux.h gcc-2.95.1/gcc/config/linux.h
151 --- gcc-2.95.1.orig/gcc/config/linux.h Wed Dec 16 21:59:55 1998
152 +++ gcc-2.95.1/gcc/config/linux.h Thu Aug 19 13:25:21 1999
154 %{!profile:%{!ggdb:-lc} %{ggdb:-lg}}}"
158 + "%{shared: -lc --version-script libgcc.map%s} \
159 %{!shared: %{mieee-fp:-lieee} %{pthread:-lpthread} \
160 %{profile:-lc_p} %{!profile: -lc}}"
162 diff -urN gcc-2.95.1.orig/gcc/config/t-linux gcc-2.95.1/gcc/config/t-linux
163 --- gcc-2.95.1.orig/gcc/config/t-linux Wed Dec 16 22:00:09 1998
164 +++ gcc-2.95.1/gcc/config/t-linux Thu Aug 19 13:25:21 1999
170 +# Make glocal functions in libgcc.a local to the shared library with
171 +# symbol versioning.
172 +LIBGCC_MAP=libgcc.map
173 +# This list has to be maintained manually. It should cover the libgcc
174 +# functions, which can be safely made local to a shared library, on
175 +# all Linux platforms.
176 +LIBGCC_MAP_LIST=__ashldi3 __ashrdi3 __builtin_saveregs __clear_cache \
177 + __cmpdi2 __divdi3 __dummy __eprintf __ffsdi2 __fixdfdi __fixsfdi \
178 + __fixunsdfdi __fixunsdfsi __fixunssfdi __fixunssfsi __fixunsxfdi \
179 + __fixunsxfsi __fixxfdi __floatdidf __floatdisf __floatdixf \
180 + __gcc_bcmp __lshrdi3 __moddi3 __muldi3 __negdi2 __pure_virtual \
181 + __ucmpdi2 __udiv_w_sdiv __udivdi3 __udivmoddi4 __umoddi3
182 +EXTRACT_LIBGCC=for s in $(LIBGCC_MAP_LIST); do echo " $$s;"; done
183 diff -urN gcc-2.95.1.orig/gcc/f/Make-lang.in gcc-2.95.1/gcc/f/Make-lang.in
184 --- gcc-2.95.1.orig/gcc/f/Make-lang.in Mon Jun 7 08:44:57 1999
185 +++ gcc-2.95.1/gcc/f/Make-lang.in Thu Aug 19 13:25:21 1999
188 f77.all.build: g77$(exeext)
189 f77.all.cross: g77-cross$(exeext)
190 -f77.start.encap: g77$(exeext)
191 +f77.start.encap: g77$(exeext) $(srcdir)/f/intdoc.texi
195 diff -urN gcc-2.95.1.orig/libf2c/Makefile.in gcc-2.95.1/libf2c/Makefile.in
196 --- gcc-2.95.1.orig/libf2c/Makefile.in Sat Aug 7 07:36:10 1999
197 +++ gcc-2.95.1/libf2c/Makefile.in Thu Aug 19 13:27:12 1999
199 # Quote this way so that it can be used to set shell variables too.
200 # Currently no use for PICFLAG, RUNTESTFLAGS -- check usage.
203 - CFLAGS='$(CFLAGS)' \
204 - CPPFLAGS='$(CPPFLAGS)' \
206 - RANLIB='$(RANLIB)' \
207 - PICFLAG='$(PICFLAG)' \
208 - RUNTESTFLAGS='$(RUNTESTFLAGS)' \
209 - prefix='$(prefix)' \
210 - exec_prefix='$(exec_prefix)' \
211 - libdir='$(libdir)' \
212 - libsubdir='$(libsubdir)' \
213 - tooldir='$(tooldir)'
215 + "CFLAGS=$(CFLAGS)" \
216 + "CPPFLAGS=$(CPPFLAGS)" \
218 + "RANLIB=$(RANLIB)" \
219 + "PICFLAG=$(PICFLAG)" \
220 + "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
221 + "prefix=$(prefix)" \
222 + "exec_prefix=$(exec_prefix)" \
223 + "libdir=$(libdir)" \
224 + "libsubdir=$(libsubdir)" \
225 + "tooldir=$(tooldir)"