aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2017-10-05 20:44:52 +0200
committerFelix Fietkau <nbd@nbd.name>2017-10-05 21:16:25 +0200
commit067221360e87fe7bd66b194feb8a080a9dbdf17c (patch)
tree9896e5ae32860eecb00bb6390b75fcacea0bed7a /tools
parenta999f91ca3f9cf0ec57de2dc62d7a77ea45822c2 (diff)
downloadupstream-067221360e87fe7bd66b194feb8a080a9dbdf17c.tar.gz
upstream-067221360e87fe7bd66b194feb8a080a9dbdf17c.tar.bz2
upstream-067221360e87fe7bd66b194feb8a080a9dbdf17c.zip
cmake: fix build error with Xcode 9 on macOS 12
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'tools')
-rw-r--r--tools/cmake/patches/010-backport-macos-fix.patch15
1 files changed, 15 insertions, 0 deletions
diff --git a/tools/cmake/patches/010-backport-macos-fix.patch b/tools/cmake/patches/010-backport-macos-fix.patch
new file mode 100644
index 0000000000..76e92dcb0e
--- /dev/null
+++ b/tools/cmake/patches/010-backport-macos-fix.patch
@@ -0,0 +1,15 @@
+--- a/Source/kwsys/kwsysPlatformTestsCXX.cxx
++++ b/Source/kwsys/kwsysPlatformTestsCXX.cxx
+@@ -265,6 +265,12 @@ int main()
+ #ifdef TEST_KWSYS_CXX_HAS_UTIMENSAT
+ #include <fcntl.h>
+ #include <sys/stat.h>
++#if defined(__APPLE__)
++#include <AvailabilityMacros.h>
++#if MAC_OS_X_VERSION_MIN_REQUIRED < 101300
++#error "utimensat not available on macOS < 10.13"
++#endif
++#endif
+ int main()
+ {
+ struct timespec times[2] = { { 0, UTIME_OMIT }, { 0, UTIME_NOW } };