about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2022-06-02 08:50:58 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2022-06-02 15:43:25 -0300
commit7d3e91ba194cc4b5fe1c9017f3bd77533c123b97 (patch)
tree831f5b16423216096ef340568dbee2305282d848
parentbb8887379f59a3efde90569acd47e63e0f6a3863 (diff)
downloadglibc-7d3e91ba194cc4b5fe1c9017f3bd77533c123b97.tar.gz
glibc-7d3e91ba194cc4b5fe1c9017f3bd77533c123b97.tar.xz
glibc-7d3e91ba194cc4b5fe1c9017f3bd77533c123b97.zip
linux: Set tst-pidfd-consts unsupported for kernels headers older than 5.10
Instead of fail trying to build the compare source file.

Reviewed-by: Carlos O'Donell <carlos@redhat.com>
Tested-by: Matheus Castanho <msc@linux.ibm.com>
Reviewed-by: Matheus Castanho <msc@linux.ibm.com>
-rw-r--r--sysdeps/unix/sysv/linux/tst-pidfd-consts.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/sysdeps/unix/sysv/linux/tst-pidfd-consts.py b/sysdeps/unix/sysv/linux/tst-pidfd-consts.py
index 75df0ebed5..90cbb9be64 100644
--- a/sysdeps/unix/sysv/linux/tst-pidfd-consts.py
+++ b/sysdeps/unix/sysv/linux/tst-pidfd-consts.py
@@ -34,6 +34,9 @@ def main():
     args = parser.parse_args()
 
     linux_version_headers = glibcsyscalls.linux_kernel_version(args.cc)
+    # Linux started to provide pidfd.h with 5.10.
+    if linux_version_headers < (5, 10):
+        sys.exit (77)
     linux_version_glibc = (5, 18)
     sys.exit(glibcextract.compare_macro_consts(
                 '#include <sys/pidfd.h>\n',