aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog7
-rw-r--r--NEWS2
-rw-r--r--sysdeps/unix/sysv/linux/Makefile11
3 files changed, 17 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index df08a3d899..d3e66932ac 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2013-07-15 Carlos O'Donell <carlos@redhat.com>
+
+ [BZ #15711]
+ * sysdeps/unix/sysv/linux/Makefile ($(objpfx)bits/syscall%h):
+ Avoid system header dependency with -ffreestanding.
+ ($(objpfx)bits/syscall%d): Likewise.
+
2013-07-13 David S. Miller <davem@davemloft.net>
* math/libm-test.inc (casin_test_data): Annotate more cases of missing
diff --git a/NEWS b/NEWS
index 56ce7ef147..c39157da61 100644
--- a/NEWS
+++ b/NEWS
@@ -21,7 +21,7 @@ Version 2.18
15395, 15405, 15406, 15409, 15416, 15418, 15419, 15423, 15424, 15426,
15429, 15431, 15432, 15441, 15442, 15448, 15465, 15480, 15485, 15488,
15490, 15492, 15493, 15497, 15506, 15529, 15536, 15553, 15577, 15583,
- 15618, 15627, 15631, 15654, 15655, 15666, 15667, 15674.
+ 15618, 15627, 15631, 15654, 15655, 15666, 15667, 15674, 15711.
* CVE-2013-0242 Buffer overrun in regexp matcher has been fixed (Bugzilla
#15078).
diff --git a/sysdeps/unix/sysv/linux/Makefile b/sysdeps/unix/sysv/linux/Makefile
index f580635c84..94916a2b13 100644
--- a/sysdeps/unix/sysv/linux/Makefile
+++ b/sysdeps/unix/sysv/linux/Makefile
@@ -50,6 +50,13 @@ tests += tst-clone
# be the condition for those options to use in a C #if condition.
# abi-includes may be defined to a list of headers to include
# in the generated header, if the default does not suffice.
+#
+# The generated header is compiled with `-ffreestanding' to avoid any
+# circular dependencies against the installed implementation headers.
+# Such a dependency would require the implementation header to be
+# installed before the generated header could be built (See bug 15711).
+# In current practice the generated header dependencies do not include
+# any of the implementation headers removed by the use of `-ffreestanding'.
$(objpfx)bits/syscall%h $(objpfx)bits/syscall%d: ../sysdeps/unix/sysv/linux/sys/syscall.h
$(make-target-directory)
@@ -64,7 +71,7 @@ $(objpfx)bits/syscall%h $(objpfx)bits/syscall%d: ../sysdeps/unix/sysv/linux/sys/
echo ''; \
$(if $(abi-variants), \
$(foreach v,$(abi-variants),\
- $(CC) -E -MD -MP -MF $(@:.h=.d)-t$(v) -MT '$(@:.d=.h) $(@:.h=.d)' \
+ $(CC) -ffreestanding -E -MD -MP -MF $(@:.h=.d)-t$(v) -MT '$(@:.d=.h) $(@:.h=.d)' \
-x c $(sysincludes) $< $(abi-$(v)-options) \
-D_LIBC -dM | \
sed -n 's@^#define __NR_\([^ ]*\) .*$$@#define SYS_\1 __NR_\1@p' | \
@@ -75,7 +82,7 @@ $(objpfx)bits/syscall%h $(objpfx)bits/syscall%d: ../sysdeps/unix/sysv/linux/sys/
$(if $(abi-$(v)-condition),echo '#endif';) \
rm -f $(@:.d=.h).new$(v); \
), \
- $(CC) -E -MD -MP -MF $(@:.h=.d)-t$(v) -MT '$(@:.d=.h) $(@:.h=.d)' \
+ $(CC) -ffreestanding -E -MD -MP -MF $(@:.h=.d)-t$(v) -MT '$(@:.d=.h) $(@:.h=.d)' \
-x c $(sysincludes) $< \
-D_LIBC -dM | \
sed -n 's@^#define __NR_\([^ ]*\) .*$$@#define SYS_\1 __NR_\1@p' | \