diff options
author | Julian Andres Klode <julian.klode@canonical.com> | 2018-04-20 11:58:09 +0200 |
---|---|---|
committer | Julian Andres Klode <julian.klode@canonical.com> | 2018-04-20 12:05:40 +0200 |
commit | 54b3de3ed85be6c8a98b35f2d3d9ec26ab3e4eee (patch) | |
tree | 808c12b8a8c0be27ecfadb70f866227ffd11a8b8 /apt-pkg/CMakeLists.txt | |
parent | 3586b5cede55c3da3e4e026c296659b86dce0782 (diff) |
CMake: Fix builds without zstd
Only use zstd defined variables if zstd was found.
Diffstat (limited to 'apt-pkg/CMakeLists.txt')
-rw-r--r-- | apt-pkg/CMakeLists.txt | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/apt-pkg/CMakeLists.txt b/apt-pkg/CMakeLists.txt index fdf27f92d..64709ce34 100644 --- a/apt-pkg/CMakeLists.txt +++ b/apt-pkg/CMakeLists.txt @@ -44,7 +44,7 @@ target_include_directories(apt-pkg ${BZIP2_INCLUDE_DIR} ${LZMA_INCLUDE_DIRS} ${LZ4_INCLUDE_DIRS} - ${ZSTD_INCLUDE_DIRS} + $<$<BOOL:${ZSTD_FOUND}>:${ZSTD_INCLUDE_DIRS}> $<$<BOOL:${UDEV_FOUND}>:${UDEV_INCLUDE_DIRS}> ${ICONV_INCLUDE_DIRS} ) @@ -56,7 +56,7 @@ target_link_libraries(apt-pkg ${BZIP2_LIBRARIES} ${LZMA_LIBRARIES} ${LZ4_LIBRARIES} - ${ZSTD_LIBRARIES} + $<$<BOOL:${ZSTD_FOUND}>:${ZSTD_LIBRARIES}> $<$<BOOL:${UDEV_FOUND}>:${UDEV_LIBRARIES}> ${ICONV_LIBRARIES} ) |