This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Your patch to libjava/java/lang/ieeefp.h
- From: Andrew Pinski <pinskia at physics dot uc dot edu>
- To: Andreas Tobler <a dot tobler at schweiz dot ch>
- Cc: gcc at gcc dot gnu dot org, java-patches at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Tue, 1 Jan 2002 22:30:14 -0500
- Subject: Your patch to libjava/java/lang/ieeefp.h
Dear Andreas Tobler,
Your patch:
2001-12-29 Andreas Tobler <a.tobler@schweiz.ch>
* libjava/java/lang/ieeefp.h: Define __IEEE_BIG_ENDIAN for
Darwin.
is wrong because Darwin runs on both PPC and ia32.
Right now both __IEEE_BIG_ENDIAN and __IEEE_LITTLE_ENDIAN will be define
on an ia32 Darwin compile.
I would change it so you only check to see if it is darwin under the PPC
one.
Here is the patch:
2002-1-1 Andrew Pinski
* libjava/java/lang/ieeefp.h: Define __IEEE_BIG_ENDIAN for
PPC Darwin, not for all of Darwin.
--- src/libjava/java/lang/ieeefp.h Tue Jan 1 22:26:55 2002
+++ src/libjava/java/lang/ieeefp.h.new Tue Jan 1 22:26:02 2002
@@ -96,12 +96,8 @@
#define __IEEE_LITTLE_ENDIAN
#endif
-#ifdef __APPLE__
-#define __IEEE_BIG_ENDIAN
-#endif
-
-#ifdef __PPC__
-#if (defined(_BIG_ENDIAN) && _BIG_ENDIAN) || (defined(_AIX) && _AIX)
+#if defined(__PPC__) || defined(__ppc__)
+#if (defined(_BIG_ENDIAN) && _BIG_ENDIAN) || (defined(_AIX) && _AIX) ||
(defined(__APPLE__))
#define __IEEE_BIG_ENDIAN
#else
#if (defined(_LITTLE_ENDIAN) && _LITTLE_ENDIAN) || (defined(__sun__) &&
__sun__) || (defined(__WIN32__) && __WIN32__)
Thanks,
Andew Pinski