diff options
author | Brad King <brad.king@kitware.com> | 2017-09-21 12:17:31 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2017-09-21 12:17:55 (GMT) |
commit | 2c0da01c4573bd4f91e78a4f95e0493be9c943ce (patch) | |
tree | b1ac38e26ba48accdce8ecf4681b92a5a2f4836b | |
parent | cc5600f9fd371cc48ac63701f39baf136491bed0 (diff) | |
parent | 96329d5dffdd5a22c5b4428119b5d3762a8857a7 (diff) | |
download | CMake-2c0da01c4573bd4f91e78a4f95e0493be9c943ce.zip CMake-2c0da01c4573bd4f91e78a4f95e0493be9c943ce.tar.gz CMake-2c0da01c4573bd4f91e78a4f95e0493be9c943ce.tar.bz2 |
Merge topic 'libarchive-macos-nanosecond'
96329d5d libarchive: Do not use nanosecond file time APIs on macOS < 10.13
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1295
-rw-r--r-- | Utilities/cmlibarchive/libarchive/archive_platform.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/Utilities/cmlibarchive/libarchive/archive_platform.h b/Utilities/cmlibarchive/libarchive/archive_platform.h index 4cb8f81..f33208c 100644 --- 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 |