diff options
-rw-r--r-- | src/corelib/configure.json | 16 | ||||
-rw-r--r-- | src/corelib/global/minimum-linux_p.h | 6 |
2 files changed, 21 insertions, 1 deletions
diff --git a/src/corelib/configure.json b/src/corelib/configure.json index a22a7459bd..5f5a00a64f 100644 --- a/src/corelib/configure.json +++ b/src/corelib/configure.json @@ -374,6 +374,16 @@ ] } }, + "glibc": { + "label": "GNU libc", + "type": "compile", + "test": { + "include": "stdlib.h", + "main": [ + "return __GLIBC__;" + ] + } + }, "inotify": { "label": "inotify", "type": "compile", @@ -593,6 +603,12 @@ "condition": "libs.glib", "output": [ "privateFeature", "feature" ] }, + "glibc": { + "label": "GNU libc", + "autoDetect": "config.linux", + "condition": "tests.glibc", + "output": [ "privateFeature" ] + }, "iconv": { "label": "iconv", "purpose": "Provides internationalization on Unix.", diff --git a/src/corelib/global/minimum-linux_p.h b/src/corelib/global/minimum-linux_p.h index 9c074e13ba..5112015663 100644 --- a/src/corelib/global/minimum-linux_p.h +++ b/src/corelib/global/minimum-linux_p.h @@ -78,7 +78,11 @@ QT_BEGIN_NAMESPACE * - statx 4.11 QT_CONFIG(statx) */ -#if QT_CONFIG(statx) +#if QT_CONFIG(statx) && !QT_CONFIG(glibc) +// if using glibc, the statx() function in sysdeps/unix/sysv/linux/statx.c +// falls back to stat() for us. +// (Using QT_CONFIG(glibc) instead of __GLIBC__ because the macros aren't +// defined in assembler mode) # define MINLINUX_MAJOR 4 # define MINLINUX_MINOR 11 # define MINLINUX_PATCH 0 |