diff options
| -rw-r--r-- | contrib/CMakeLists.txt | 4 | ||||
| -rw-r--r-- | contrib/testzlib/CMakeLists.txt | 22 |
2 files changed, 26 insertions, 0 deletions
diff --git a/contrib/CMakeLists.txt b/contrib/CMakeLists.txt index fab97ac..3e2eb43 100644 --- a/contrib/CMakeLists.txt +++ b/contrib/CMakeLists.txt | |||
| @@ -38,3 +38,7 @@ zlib_add_contrib_lib(BLAST "blast binary" blast) | |||
| 38 | zlib_add_contrib_lib(IOSTREAM3 "IOStream C++ bindings V3" iostream3) | 38 | zlib_add_contrib_lib(IOSTREAM3 "IOStream C++ bindings V3" iostream3) |
| 39 | zlib_add_contrib_lib(MINIZIP "minizip library" minizip) | 39 | zlib_add_contrib_lib(MINIZIP "minizip library" minizip) |
| 40 | zlib_add_contrib_lib(PUFF "puff decompress library" puff) | 40 | zlib_add_contrib_lib(PUFF "puff decompress library" puff) |
| 41 | |||
| 42 | if(WIN32) | ||
| 43 | zlib_add_contrib_lib(TESTZLIB "testzlib binary" testzlib) | ||
| 44 | endif(WIN32) | ||
diff --git a/contrib/testzlib/CMakeLists.txt b/contrib/testzlib/CMakeLists.txt new file mode 100644 index 0000000..d68b533 --- /dev/null +++ b/contrib/testzlib/CMakeLists.txt | |||
| @@ -0,0 +1,22 @@ | |||
| 1 | cmake_minimum_required(VERSION 3.12...3.31) | ||
| 2 | |||
| 3 | project( | ||
| 4 | testzlib | ||
| 5 | VERSION 1.0.0 | ||
| 6 | LANGUAGES C | ||
| 7 | DESCRIPTION "A little program to test zlib" | ||
| 8 | HOMEPAGE_URL "https://www.zlib.net") | ||
| 9 | |||
| 10 | option(ZLIB_TESTZLIB_BUILD_SHARED "Enable building testzlib" ON) | ||
| 11 | option(ZLIB_TESTZLIB_BUILD_STATIC "Enable building static linked testzlib" ON) | ||
| 12 | option(ZLIB_TESTZLIB_BUILD_TESTING "Enable building tests for testzlib" ON) | ||
| 13 | |||
| 14 | if(ZLIB_TESTZLIB_BUILD_SHARED) | ||
| 15 | add_executable(testzlib testzlib.c) | ||
| 16 | target_link_libraries(testzlib PRIVATE ZLIB::ZLIB) | ||
| 17 | endif(ZLIB_TESTZLIB_BUILD_SHARED) | ||
| 18 | |||
| 19 | if(ZLIB_TESTZLIB_BUILD_STATIC) | ||
| 20 | add_executable(testzlibStatic testzlib.c) | ||
| 21 | target_link_libraries(testzlibStatic PRIVATE ZLIB::ZLIBSTATIC) | ||
| 22 | endif(ZLIB_TESTZLIB_BUILD_STATIC) | ||
