This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PowerPC] Fix PR 26607, 4.1 build failure for gnuspe
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: gcc-patches at gcc dot gnu dot org
- Date: Tue, 21 Mar 2006 16:40:12 +1030
- Subject: [PowerPC] Fix PR 26607, 4.1 build failure for gnuspe
4.1 powerpc-unknown-linux-gnuspe fails to build because darwin-ldouble.c
won't compile without fp regs (more than that, e500 doesn't even support
the fmsub insn used in the offending asm). Rather than tweak the
t-files, I figured it was better to adjust the conditional compilation
test at the start of darwin-ldouble.c. Instead of using _SOFT_FLOAT,
use __NO_FPRS__. I also added a __LITTLE_ENDIAN__ test, and removed the
redundant __powerpc64__ test.
Tested with a powerpc-linux to powerpc-linuxspe cross and a
powerpc64-linux native build.
PR target/26607
* config/rs6000/darwin-ldouble.c: Modify #if file wrapper.
Index: gcc/config/rs6000/darwin-ldouble.c
===================================================================
--- gcc/config/rs6000/darwin-ldouble.c (revision 112216)
+++ gcc/config/rs6000/darwin-ldouble.c (working copy)
@@ -49,7 +49,8 @@
This code currently assumes big-endian. */
-#if !_SOFT_FLOAT && (defined (__MACH__) || defined (__powerpc64__) || defined (__powerpc__) || defined (_AIX))
+#if (!defined (__NO_FPRS__) && !defined (__LITTLE_ENDIAN__) \
+ && (defined (__MACH__) || defined (__powerpc__) || defined (_AIX)))
#define fabs(x) __builtin_fabs(x)
#define isless(x, y) __builtin_isless (x, y)
--
Alan Modra
IBM OzLabs - Linux Technology Centre