70 lines
2.3 KiB
Diff
70 lines
2.3 KiB
Diff
From 0fc1e355f07235ca7fe1f04d7206394772c6b5f4 Mon Sep 17 00:00:00 2001
|
|
From: Martchus <martchus@gmx.net>
|
|
Date: Sat, 25 Aug 2018 11:44:46 +0200
|
|
Subject: [PATCH 34/34] Fix build error related to glibc 2.28 and stat
|
|
|
|
Taken from regular package, comes from Fedora
|
|
---
|
|
mkspecs/linux-g++/qplatformdefs.h | 2 ++
|
|
src/corelib/io/qfilesystemengine_unix.cpp | 10 +++++++---
|
|
2 files changed, 9 insertions(+), 3 deletions(-)
|
|
|
|
diff --git a/mkspecs/linux-g++/qplatformdefs.h b/mkspecs/linux-g++/qplatformdefs.h
|
|
index 13523f0702..d32453162c 100644
|
|
--- a/mkspecs/linux-g++/qplatformdefs.h
|
|
+++ b/mkspecs/linux-g++/qplatformdefs.h
|
|
@@ -72,7 +72,9 @@
|
|
#include <sys/time.h>
|
|
#include <sys/shm.h>
|
|
#include <sys/socket.h>
|
|
+#if 0
|
|
#include <sys/stat.h>
|
|
+#endif
|
|
#include <sys/wait.h>
|
|
#include <netinet/in.h>
|
|
|
|
diff --git a/src/corelib/io/qfilesystemengine_unix.cpp b/src/corelib/io/qfilesystemengine_unix.cpp
|
|
index be6ce48d0c..3648cfc43d 100644
|
|
--- a/src/corelib/io/qfilesystemengine_unix.cpp
|
|
+++ b/src/corelib/io/qfilesystemengine_unix.cpp
|
|
@@ -50,7 +50,9 @@
|
|
#include <pwd.h>
|
|
#include <stdlib.h> // for realpath()
|
|
#include <sys/types.h>
|
|
+#if 0
|
|
#include <sys/stat.h>
|
|
+#endif
|
|
#include <unistd.h>
|
|
#include <stdio.h>
|
|
#include <errno.h>
|
|
@@ -91,7 +93,9 @@ extern "C" NSString *NSTemporaryDirectory();
|
|
# include <sys/syscall.h>
|
|
# include <sys/sendfile.h>
|
|
# include <linux/fs.h>
|
|
+#if 0
|
|
# include <linux/stat.h>
|
|
+#endif
|
|
|
|
// in case linux/fs.h is too old and doesn't define it:
|
|
#ifndef FICLONE
|
|
@@ -105,13 +109,13 @@ extern "C" NSString *NSTemporaryDirectory();
|
|
# undef SYS_renameat2
|
|
# undef SYS_statx
|
|
# undef STATX_BASIC_STATS
|
|
-# else
|
|
-# if !QT_CONFIG(renameat2) && defined(SYS_renameat2)
|
|
+# else
|
|
+# if 0 && !QT_CONFIG(renameat2) && defined(SYS_renameat2)
|
|
static int renameat2(int oldfd, const char *oldpath, int newfd, const char *newpath, unsigned flags)
|
|
{ return syscall(SYS_renameat2, oldfd, oldpath, newfd, newpath, flags); }
|
|
# endif
|
|
|
|
-# if !QT_CONFIG(statx) && defined(SYS_statx)
|
|
+# if 0 && !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)
|
|
--
|
|
2.18.0
|
|
|