diff options
author | DongHun Kwak <dh0128.kwak@samsung.com> | 2018-12-04 14:04:28 +0900 |
---|---|---|
committer | DongHun Kwak <dh0128.kwak@samsung.com> | 2018-12-04 14:04:32 +0900 |
commit | e679b515eddb3dd340fb25620de0160211f40fdc (patch) | |
tree | 93271e0bbd40dba805f8270cfc78a3ac10ab2c8f /CMakeLists.txt | |
parent | d98199487aa414cb7f965a058c4395235343e20a (diff) | |
download | libsolv-e679b515eddb3dd340fb25620de0160211f40fdc.tar.gz libsolv-e679b515eddb3dd340fb25620de0160211f40fdc.tar.bz2 libsolv-e679b515eddb3dd340fb25620de0160211f40fdc.zip |
Imported Upstream version 0.6.35upstream/0.6.35
Change-Id: Ib7359aa10c08c1469105fbd6a82ea922f46f8b51
Signed-off-by: DongHun Kwak <dh0128.kwak@samsung.com>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 24 |
1 files changed, 14 insertions, 10 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 2557f0a..8c6a1be 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -33,17 +33,11 @@ OPTION (MULTI_SEMANTICS "Build with support for multiple distribution types?" OF OPTION (ENABLE_LZMA_COMPRESSION "Build with lzma/xz compression support?" OFF) OPTION (ENABLE_BZIP2_COMPRESSION "Build with bzip2 compression support?" OFF) +OPTION (ENABLE_ZSTD_COMPRESSION "Build with zstd compression support?" OFF) +OPTION (ENABLE_ZCHUNK_COMPRESSION "Build with zchunk compression support?" OFF) OPTION (WITH_LIBXML2 "Build with libxml2 instead of libexpat?" OFF) -#IF(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERISION} GREATER 2.4) -#ENDIF(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERISION} GREATER 2.4) - -IF (COMMAND cmake_policy) - # escape preprocessor, see -DVERSION below - CMAKE_POLICY (SET CMP0005 OLD) -ENDIF (COMMAND cmake_policy) - # Library IF (DEFINED LIB) SET (LIB_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/${LIB}") @@ -162,6 +156,10 @@ IF (ENABLE_ARCHREPO OR ENABLE_DEBIAN) SET (ENABLE_LZMA_COMPRESSION ON) ENDIF (ENABLE_ARCHREPO OR ENABLE_DEBIAN) +IF (ENABLE_ZCHUNK_COMPRESSION) +SET (ENABLE_ZSTD_COMPRESSION ON) +ENDIF (ENABLE_ZCHUNK_COMPRESSION) + IF (ENABLE_RPMMD OR ENABLE_SUSEREPO OR ENABLE_APPDATA OR ENABLE_COMPS OR ENABLE_HELIXREPO OR ENABLE_MDKREPO) IF (WITH_LIBXML2 ) FIND_PACKAGE (LibXml2 REQUIRED) @@ -184,6 +182,10 @@ IF (ENABLE_BZIP2_COMPRESSION) FIND_PACKAGE (BZip2 REQUIRED) ENDIF (ENABLE_BZIP2_COMPRESSION) +IF (ENABLE_ZSTD_COMPRESSION) +FIND_LIBRARY (ZSTD_LIBRARY NAMES zstd) +ENDIF (ENABLE_ZSTD_COMPRESSION) + IF (RPM5) MESSAGE (STATUS "Enabling RPM 5 support") ADD_DEFINITIONS (-DRPM5) @@ -292,7 +294,7 @@ FOREACH (VAR ENABLE_SUSEREPO ENABLE_COMPS ENABLE_TESTCASE_HELIXREPO ENABLE_HELIXREPO ENABLE_MDKREPO ENABLE_ARCHREPO ENABLE_DEBIAN ENABLE_HAIKU ENABLE_ZLIB_COMPRESSION ENABLE_LZMA_COMPRESSION ENABLE_BZIP2_COMPRESSION - ENABLE_PGPVRFY ENABLE_APPDATA) + ENABLE_ZSTD_COMPRESSION ENABLE_ZCHUNK_COMPRESSION ENABLE_PGPVRFY ENABLE_APPDATA) IF(${VAR}) ADD_DEFINITIONS (-D${VAR}=1) SET (SWIG_FLAGS ${SWIG_FLAGS} -D${VAR}) @@ -305,7 +307,6 @@ SET (PACKAGE "libsolv") SET (VERSION "${LIBSOLV_MAJOR}.${LIBSOLV_MINOR}.${LIBSOLV_PATCH}") ADD_DEFINITIONS (-D_FILE_OFFSET_BITS=64) -ADD_DEFINITIONS (-DVERSION=\\\"${VERSION}\\\") CONFIGURE_FILE (src/solvversion.h.in src/solvversion.h) SET (CPACK_PACKAGE_DESCRIPTION_SUMMARY "Package dependency solver library") @@ -395,6 +396,9 @@ ENDIF (ENABLE_LZMA_COMPRESSION) IF (ENABLE_BZIP2_COMPRESSION) SET (SYSTEM_LIBRARIES ${SYSTEM_LIBRARIES} ${BZIP2_LIBRARIES}) ENDIF (ENABLE_BZIP2_COMPRESSION) +IF (ENABLE_ZSTD_COMPRESSION) +SET (SYSTEM_LIBRARIES ${SYSTEM_LIBRARIES} ${ZSTD_LIBRARY}) +ENDIF (ENABLE_ZSTD_COMPRESSION) IF (ENABLE_RPMDB) SET (SYSTEM_LIBRARIES ${RPMDB_LIBRARY} ${SYSTEM_LIBRARIES}) ENDIF (ENABLE_RPMDB) |