This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] [ia64] Make all of sysdeps/ia64/fpu/libm-symbols.h only visible to libc||libm


When experimenting with Joseph's build-many-glibcs.py I found that
sysdeps/ia64/fpu/libm-symbols.h and the -D switches added to the command
line by sysdeps/ia64/fpu/Makefile can break the math tests.  This patch
moves the -D switches into libm-symbols.h and makes that file only apply
when IS_IN(libc)||IS_IN(libm), which is sufficient to clear the test
failure I observed.

Tested (cross compile only) on ia64-linux-gnu. OK?

zw

---
 sysdeps/ia64/fpu/Makefile       |  6 +-----
 sysdeps/ia64/fpu/libm-symbols.h | 15 +++++++++++++++
 2 files changed, 16 insertions(+), 5 deletions(-)

diff --git a/sysdeps/ia64/fpu/Makefile b/sysdeps/ia64/fpu/Makefile
index 384fc83..450d712 100644
--- a/sysdeps/ia64/fpu/Makefile
+++ b/sysdeps/ia64/fpu/Makefile
@@ -26,9 +26,5 @@ libm-sysdep_routines += s_erfc s_erfcf s_erfcl \
 sysdep_routines += libc_libm_error libm_frexp libm_frexpf libm_frexpl \
 		   $(duplicated-routines)
 -sysdep-CPPFLAGS += -include libm-symbols.h \
-	-D__POSIX__ -Dopensource \
-	-D_LIB_VERSIONIMF=_LIB_VERSION \
-	-DSIZE_INT_32 -DSIZE_LONG_INT_64 -DSIZE_LONG_LONG_INT_64 \
-	-DSIZE_LONG_64 -DIA64
+sysdep-CPPFLAGS += -include libm-symbols.h
 endif
diff --git a/sysdeps/ia64/fpu/libm-symbols.h
b/sysdeps/ia64/fpu/libm-symbols.h
index 3cbc6c4..62c9adb 100644
--- a/sysdeps/ia64/fpu/libm-symbols.h
+++ b/sysdeps/ia64/fpu/libm-symbols.h
@@ -1,3 +1,16 @@
+#if IS_IN (libc) || IS_IN (libm)
+
+/* The externally maintained code in this directory expects these
+   macros to be defined.  */
+#define __POSIX__ 1
+#define opensource 1
+#define _LIB_VERSIONIMF _LIB_VERSION
+#define SIZE_INT_32 1
+#define SIZE_LONG_INT_64 1
+#define SIZE_LONG_LONG_INT_64 1
+#define SIZE_LONG_64 1
+#define IA64 1
+
 #include <sysdep.h>
 #undef ret	/* get rid of the stupid "ret" macro; it breaks br.ret */
 @@ -56,3 +69,5 @@
 #if defined ASSEMBLER && IS_IN (libc)
 # define __libm_error_support	HIDDEN_JUMPTARGET(__libm_error_support)
 #endif
+
+#endif
-- 
2.10.2


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]