summaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt55
1 files changed, 35 insertions, 20 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b2ab30e..9de5338 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,7 +1,7 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
-cmake_minimum_required(VERSION 3.1...3.21 FATAL_ERROR)
+cmake_minimum_required(VERSION 3.13...3.22 FATAL_ERROR)
set(CMAKE_USER_MAKE_RULES_OVERRIDE_C ${CMAKE_CURRENT_SOURCE_DIR}/Source/Modules/OverrideC.cmake)
set(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX ${CMAKE_CURRENT_SOURCE_DIR}/Source/Modules/OverrideCXX.cmake)
@@ -606,25 +606,40 @@ macro (CMAKE_BUILD_UTILITIES)
set(ZLIB_INCLUDE_DIR ${CMAKE_ZLIB_INCLUDES})
set(ZLIB_LIBRARY ${CMAKE_ZLIB_LIBRARIES})
add_definitions(-DLIBARCHIVE_STATIC)
- set(ENABLE_MBEDTLS OFF CACHE INTERNAL "Enable use of mbed TLS")
- set(ENABLE_NETTLE OFF CACHE INTERNAL "Enable use of Nettle")
- set(ENABLE_OPENSSL ${CMAKE_USE_OPENSSL} CACHE INTERNAL "Enable use of OpenSSL")
- set(ENABLE_LIBB2 OFF CACHE INTERNAL "Enable the use of the system LIBB2 library if found")
- set(ENABLE_LZMA ON CACHE INTERNAL "Enable the use of the system LZMA library if found")
- set(ENABLE_LZ4 OFF CACHE INTERNAL "Enable the use of the system LZ4 library if found")
- set(ENABLE_LZO OFF CACHE INTERNAL "Enable the use of the system LZO library if found")
- set(ENABLE_ZLIB ON CACHE INTERNAL "Enable the use of the system ZLIB library if found")
- set(ENABLE_BZip2 ON CACHE INTERNAL "Enable the use of the system BZip2 library if found")
- set(ENABLE_ZSTD ON CACHE INTERNAL "Enable the use of the system zstd library if found")
- set(ENABLE_LIBXML2 OFF CACHE INTERNAL "Enable the use of the system libxml2 library if found")
- set(ENABLE_EXPAT OFF CACHE INTERNAL "Enable the use of the system EXPAT library if found")
- set(ENABLE_PCREPOSIX OFF CACHE INTERNAL "Enable the use of the system PCREPOSIX library if found")
- set(ENABLE_LibGCC OFF CACHE INTERNAL "Enable the use of the system LibGCC library if found")
- set(ENABLE_XATTR OFF CACHE INTERNAL "Enable extended attribute support")
- set(ENABLE_ACL OFF CACHE INTERNAL "Enable ACL support")
- set(ENABLE_ICONV OFF CACHE INTERNAL "Enable iconv support")
- set(ENABLE_CNG OFF CACHE INTERNAL "Enable the use of CNG(Crypto Next Generation)")
- SET(POSIX_REGEX_LIB "" CACHE INTERNAL "Choose what library should provide POSIX regular expression support")
+ set(ENABLE_MBEDTLS OFF)
+ set(ENABLE_NETTLE OFF)
+ if(DEFINED CMAKE_USE_OPENSSL)
+ set(ENABLE_OPENSSL "${CMAKE_USE_OPENSSL}")
+ else()
+ set(ENABLE_OPENSSL OFF)
+ endif()
+ set(ENABLE_LIBB2 OFF)
+ set(ENABLE_LZ4 OFF)
+ set(ENABLE_LZO OFF)
+ set(ENABLE_LZMA ON)
+ set(ENABLE_ZSTD ON)
+ set(ENABLE_ZLIB ON)
+ set(ENABLE_BZip2 ON)
+ set(ENABLE_LIBXML2 OFF)
+ set(ENABLE_EXPAT OFF)
+ set(ENABLE_PCREPOSIX OFF)
+ set(ENABLE_LibGCC OFF)
+ set(ENABLE_CNG OFF)
+ set(ENABLE_TAR OFF)
+ set(ENABLE_TAR_SHARED OFF)
+ set(ENABLE_CPIO OFF)
+ set(ENABLE_CPIO_SHARED OFF)
+ set(ENABLE_CAT OFF)
+ set(ENABLE_CAT_SHARED OFF)
+ set(ENABLE_XATTR OFF)
+ set(ENABLE_ACL OFF)
+ set(ENABLE_ICONV OFF)
+ set(ENABLE_TEST OFF)
+ set(ENABLE_COVERAGE OFF)
+ set(ENABLE_INSTALL OFF)
+ set(POSIX_REGEX_LIB "" CACHE INTERNAL "libarchive: No POSIX regular expression support")
+ set(ENABLE_SAFESEH "" CACHE INTERNAL "libarchive: No /SAFESEH linker flag")
+ set(WINDOWS_VERSION "WIN7" CACHE INTERNAL "libarchive: Set Windows version to use (Windows only)")
add_subdirectory(Utilities/cmlibarchive)
CMAKE_SET_TARGET_FOLDER(cmlibarchive "Utilities/3rdParty")
set(CMAKE_TAR_LIBRARIES cmlibarchive ${BZIP2_LIBRARIES})