討論區: 公開討論 (Thread #3585)

gcc 3.3 elf patch (2003-10-21 05:23 by jsg12345 #6312)

please change the end of gcc 3.3 elf patch for

diff -Nru gcc-3.3/gcc/config/h8300/t-h8300 gcc-3.3-h8300/gcc/config/h8300/t-h8300
--- gcc-3.3/gcc/config/h8300/t-h8300 2002-11-20 13:54:39.000000000 +0900
+++ gcc-3.3-h8300/gcc/config/h8300/t-h8300 2003-07-26 20:42:10.000000000 +0900
@@ -5,18 +5,24 @@
LIB1ASMFUNCS = _cmpsi2 _ucmpsi2 _divhi3 _divsi3 _mulhi3 _mulsi3 \
_floatdisf _fixsfdi _fixunssfdi _fixunssfsi_asm

-LIB2FUNCS_EXTRA = $(srcdir)/config/h8300/fixunssfsi.c
-
-# We do not have DF or DI types, so fake out the libgcc2 compilation.
-TARGET_LIBGCC2_CFLAGS = -DDF=SF -DDI=SI
+LIB2FUNCS_EXTRA = $(srcdir)/config/h8300/fixunssfsi.c $(srcdir)/config/h8300/extfloatlib.c

# We want fine grained libraries, so use the new code to build the
# floating point emulation libraries.
FPBIT = fp-bit.c
+DPBIT = dp-bit.c
+
+dp-bit.c: $(srcdir)/config/fp-bit.c
+ echo '#define SMALL_MACHINE' >> dp-bit.c
+ echo '#ifdef __H8300__' >> dp-bit.c
+ echo '#define CMPtype HItype' >> dp-bit.c
+ echo '#else' >> dp-bit.c
+ echo '#define CMPtype SItype' >> dp-bit.c
+ echo '#endif' >> dp-bit.c
+ echo '#if __INT_MAX__ == 32767' >> dp-bit.c
+ echo '#define NO_DI_MODE' >> dp-bit.c
+ echo '#endif' >> dp-bit.c
+ cat $(srcdir)/config/fp-bit.c >> dp-bit.c

fp-bit.c: $(srcdir)/config/fp-bit.c
echo '#define FLOAT' > fp-bit.c
- echo '#define FLOAT_ONLY' >> fp-bit.c
echo '#define SMALL_MACHINE' >> fp-bit.c
echo '#ifdef __H8300__' >> fp-bit.c
echo '#define CMPtype HItype' >> fp-bit.c
echo '#else' >> fp-bit.c
echo '#define CMPtype SItype' >> fp-bit.c
echo '#endif' >> fp-bit.c
+ echo '#if __INT_MAX__ == 32767' >> fp-bit.c
+ echo '#define NO_DI_MODE' >> fp-bit.c
+ echo '#endif' >> fp-bit.c
cat $(srcdir)/config/fp-bit.c >> fp-bit.c


This will fix the float multiply problem when compiling without -mint32

回覆 #6312×

You can not use Wiki syntax
You are not logged in. To discriminate your posts from the rest, you need to pick a nickname. (The uniqueness of nickname is not reserved. It is possible that someone else could use the exactly same nickname. If you want assurance of your identity, you are recommended to login before posting.) 登入

RE: gcc 3.3 elf patch (2003-10-22 22:21 by ysato #6338)

Thank you.
I corrected it.
回覆: #6312

回覆 #6338×

You can not use Wiki syntax
You are not logged in. To discriminate your posts from the rest, you need to pick a nickname. (The uniqueness of nickname is not reserved. It is possible that someone else could use the exactly same nickname. If you want assurance of your identity, you are recommended to login before posting.) 登入