From b46d250656794e63a2946c481fda29271342dd1a Mon Sep 17 00:00:00 2001 From: Adhemerval Zanella Date: Mon, 21 Feb 2022 08:32:32 -0300 Subject: Remove kernel version check The kernel version check is used to avoid glibc to run on older kernels where some syscall are not available and fallback code are not enabled to handle graciously fail. However, it does not prevent if the kernel does not correctly advertise its version through vDSO note, uname or procfs. Also kernel version checks are sometime not desirable by users, where they want to deploy on different system with different kernel version knowing the minimum set of syscall is always presented on such systems. The kernel version check has been removed along with the LD_ASSUME_KERNEL environment variable. The minimum kernel used to built glibc is still provided through NT_GNU_ABI_TAG ELF note and also printed when libc.so is issued. Checked on x86_64-linux-gnu. --- sysdeps/unix/sysv/linux/configure | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'sysdeps/unix/sysv/linux/configure') diff --git a/sysdeps/unix/sysv/linux/configure b/sysdeps/unix/sysv/linux/configure index 4ff02c9..312055c 100644 --- a/sysdeps/unix/sysv/linux/configure +++ b/sysdeps/unix/sysv/linux/configure @@ -70,6 +70,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kernel header at least $minimum_kernel" >&5 $as_echo_n "checking for kernel header at least $minimum_kernel... " >&6; } decnum=`echo "$minimum_kernel.0.0.0" | sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\).*/(\1 * 65536 + \2 * 256 + \3)/'`; +abinumstr=`echo "$minimum_kernel.0.0.0" | sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\).*/\1.\2.\3/'`; abinum=`echo "$minimum_kernel.0.0.0" | sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\).*/\1,\2,\3/'`; cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -99,6 +100,10 @@ if test "$libc_minimum_kernel" = ok; then _ACEOF cat >>confdefs.h <<_ACEOF +#define __LINUX_KERNEL_VERSION_STR "$abinumstr" +_ACEOF + + cat >>confdefs.h <<_ACEOF #define __ABI_TAG_VERSION $abinum _ACEOF -- cgit v1.1