]> git.ipfire.org Git - thirdparty/glibc.git/blobdiff - Rules
hurd: Fix build
[thirdparty/glibc.git] / Rules
diff --git a/Rules b/Rules
index e08a28d9f382f526b5c4fabfe891192e755c15b8..222dba6dcbad47d0cac0d2481ca5188b04339379 100644 (file)
--- a/Rules
+++ b/Rules
@@ -82,7 +82,8 @@ $(common-objpfx)dummy.c:
 common-generated += dummy.o dummy.c
 
 ifneq "$(headers)" ""
-# Special test of all the installed headers in this directory.
+# Test that all of the headers installed by this directory can be compiled
+# in isolation.
 tests-special += $(objpfx)check-installed-headers-c.out
 libof-check-installed-headers-c := testsuite
 $(objpfx)check-installed-headers-c.out: \
@@ -93,6 +94,8 @@ $(objpfx)check-installed-headers-c.out: \
        $(evaluate-test)
 
 ifneq "$(CXX)" ""
+# If a C++ compiler is available, also test that they can be compiled
+# in isolation as C++.
 tests-special += $(objpfx)check-installed-headers-cxx.out
 libof-check-installed-headers-cxx := testsuite
 $(objpfx)check-installed-headers-cxx.out: \
@@ -103,12 +106,24 @@ $(objpfx)check-installed-headers-cxx.out: \
        $(evaluate-test)
 endif # $(CXX)
 
+# Test that a wrapper header exists in include/ for each non-sysdeps header.
+# This script does not need $(py-env).
 tests-special += $(objpfx)check-wrapper-headers.out
 $(objpfx)check-wrapper-headers.out: \
   $(..)scripts/check-wrapper-headers.py $(headers)
        $(PYTHON) $< --root=$(..) --subdir=$(subdir) $(headers) > $@; \
          $(evaluate-test)
 
+# Test that none of the headers installed by this directory use certain
+# obsolete constructs (e.g. legacy BSD typedefs superseded by stdint.h).
+# This script does not need $(py-env).
+tests-special += $(objpfx)check-obsolete-constructs.out
+libof-check-obsolete-constructs := testsuite
+$(objpfx)check-obsolete-constructs.out: \
+    $(..)scripts/check-obsolete-constructs.py $(headers)
+       $(PYTHON) $^ > $@ 2>&1; \
+       $(evaluate-test)
+
 endif # $(headers)
 \f
 # This makes all the auxiliary and test programs.