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 11:58:31 +0200 |
commit | 7973fa4f9cdc889059bb0a382715776d1f38429c (patch) | |
tree | 9a6d7a6d3942f66750f5396a323c7beb6cc50244 /apt-pkg/CMakeLists.txt | |
parent | 2e41027fc301dfc73114562406380d223f68470e (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} ) |