summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2018-03-23 08:58:01 +0800
committerJani Heikkinen <jani.heikkinen@qt.io>2018-05-14 04:46:28 +0000
commit6eef81ee1c82f934e14d47047d8b6103b8755321 (patch)
tree092a3a93b91d0ab958f8fea363c955dca18a38b8
parenta7863a58545a6c59eaf16f36905efcbf0e4f94f9 (diff)
QFileSystemEngine: don't try to use statx(2) if SYS_statx isn't definedv5.11.0-rc2v5.11.0
If glibc's <unistd.h> does not define SYS_statx but <linux/stat.h> did define struct statx and related constants, we failed to compile. Task-number: QTBUG-68205 Change-Id: I04a43ee94975482f9e32fffd151e66bbe6988554 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
-rw-r--r--src/corelib/io/qfilesystemengine_unix.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/corelib/io/qfilesystemengine_unix.cpp b/src/corelib/io/qfilesystemengine_unix.cpp
index b8cf42a2e9..be6ce48d0c 100644
--- a/src/corelib/io/qfilesystemengine_unix.cpp
+++ b/src/corelib/io/qfilesystemengine_unix.cpp
@@ -114,6 +114,8 @@ static int renameat2(int oldfd, const char *oldpath, int newfd, const char *newp
# if !QT_CONFIG(statx) && defined(SYS_statx)
static int statx(int dirfd, const char *pathname, int flag, unsigned mask, struct statx *statxbuf)
{ return syscall(SYS_statx, dirfd, pathname, flag, mask, statxbuf); }
+# elif !QT_CONFIG(statx) && !defined(SYS_statx)
+# undef STATX_BASIC_STATS
# endif
# endif // !Q_OS_ANDROID
#endif