diff options
author | Lukas Obermann <obermann.lukas@gmail.com> | 2017-10-21 15:20:11 +0200 |
---|---|---|
committer | Memphiz <memphis@machzwo.de> | 2017-10-30 00:32:23 +0100 |
commit | 10d2727df5113089f6517e44b4ac38267404d389 (patch) | |
tree | 0224786deaf22247351d8f245f64b0926bd02ee5 /tools | |
parent | 3f66b5d6c554cb21f5233abf37b2158700dc8fcd (diff) |
[depends/cmake-native] - Updated CMake to 3.9.4 and patched for macosx 10.13
Diffstat (limited to 'tools')
-rw-r--r-- | tools/depends/native/cmake-native/01-osx-utimensat.diff | 35 | ||||
-rw-r--r-- | tools/depends/native/cmake-native/Makefile | 9 |
2 files changed, 40 insertions, 4 deletions
diff --git a/tools/depends/native/cmake-native/01-osx-utimensat.diff b/tools/depends/native/cmake-native/01-osx-utimensat.diff new file mode 100644 index 0000000000..8ba4563a0d --- /dev/null +++ b/tools/depends/native/cmake-native/01-osx-utimensat.diff @@ -0,0 +1,35 @@ +--- 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 } }; +--- a/Utilities/cmlibarchive/libarchive/archive_platform.h ++++ b/Utilities/cmlibarchive/libarchive/archive_platform.h +@@ -52,6 +52,17 @@ + #error Oops: No config.h and no pre-built configuration in archive_platform.h. + #endif + ++/* On macOS check for some symbols based on the deployment target version. */ ++#if defined(__APPLE__) ++# undef HAVE_FUTIMENS ++# undef HAVE_UTIMENSAT ++# include <AvailabilityMacros.h> ++# if MAC_OS_X_VERSION_MIN_REQUIRED >= 101300 ++# define HAVE_FUTIMENS 1 ++# define HAVE_UTIMENSAT 1 ++# endif ++#endif ++ + /* It should be possible to get rid of this by extending the feature-test + * macros to cover Windows API functions, probably along with non-trivial + * refactoring of code to find structures that sit more cleanly on top of diff --git a/tools/depends/native/cmake-native/Makefile b/tools/depends/native/cmake-native/Makefile index 77e55535ac..614856bfa3 100644 --- a/tools/depends/native/cmake-native/Makefile +++ b/tools/depends/native/cmake-native/Makefile @@ -1,16 +1,16 @@ include ../../Makefile.include PLATFORM=$(NATIVEPLATFORM) -DEPS= ../../Makefile.include Makefile +DEPS= ../../Makefile.include Makefile 01-osx-utimensat.diff APPNAME=cmake -VERSION=3.6.2 +VERSION=3.9.4 SOURCE=$(APPNAME)-$(VERSION) ARCHIVE=$(SOURCE).tar.gz # configuration settings -SETENV=CC="$(CC_FOR_BUILD)" CXX="$(CXX_FOR_BUILD)" LD=$(LD_FOR_BUILD) CFLAGS=$(NATIVE_CFLAGS) \ - CXXFLAGS=$(NATIVE_CXXFLAGS) LDFLAGS=$(NATIVE_LDFLAGS) +SETENV=CC="$(CC_FOR_BUILD)" CXX="$(CXX_FOR_BUILD)" LD=$(LD_FOR_BUILD) CFLAGS="$(NATIVE_CFLAGS)" \ + CXXFLAGS="$(NATIVE_CXXFLAGS)" LDFLAGS="$(NATIVE_LDFLAGS)" ifeq ($(NATIVE_OS), osx) SETENV+=SDKROOT=$(shell xcrun --show-sdk-path) @@ -33,6 +33,7 @@ $(TARBALLS_LOCATION)/$(ARCHIVE): $(PLATFORM): $(TARBALLS_LOCATION)/$(ARCHIVE) $(DEPS) -rm -rf $(PLATFORM)/*; mkdir -p $(PLATFORM) cd $(PLATFORM); $(ARCHIVE_TOOL) $(ARCHIVE_TOOL_FLAGS) $(TARBALLS_LOCATION)/$(ARCHIVE) + cd $(PLATFORM); patch -p1 -i ../01-osx-utimensat.diff cd $(PLATFORM); $(SETENV) $(CONFIGURE) $(APP): $(PLATFORM) |