]> granicus.if.org Git - zziplib/blob - CMakeLists.txt
ZZIP_LIBLATEST: create symlinks only if target is missing
[zziplib] / CMakeLists.txt
1 cmake_minimum_required (VERSION 3.1)
2 project(zziplib VERSION "0.13.72" LANGUAGES C)
3
4 if(NOT CMAKE_BUILD_TYPE) 
5     set(CMAKE_BUILD_TYPE Release)
6 endif(NOT CMAKE_BUILD_TYPE)
7
8 ### Path to additional CMake modules
9 # set(CMAKE_MODULE_PATH
10 #     ${CMAKE_SOURCE_DIR}/cmake
11 #     ${CMAKE_MODULE_PATH})
12
13 include ( GNUInstallDirs )
14
15 option(BUILD_SHARED_LIBS "Build a shared library" ON)
16 option(BUILD_TESTS "Build test programs" OFF)
17 option(MSVC_STATIC_RUNTIME "Build with static runtime libs (/MT)" ON)
18 option(ZZIPMMAPPED "Build libzzipmmapped (not fully portable)" ON)
19 option(ZZIPFSEEKO "Build libzzipfseeko (based on posix.1 api)" ON)
20 option(ZZIPWRAP "Build libzzipwrap (non-installed example)" ON)
21 option(ZZIPSDL "Build zzcatsdl (includable example code)" ON)
22 option(ZZIPBINS "Build bins/unzzip (unzip-like executables)" ON)
23 option(ZZIPTEST "Build test/zzipself (self-extract example)" ON)
24 option(ZZIPDOCS "Build docs/manpages (and website content)" ON)
25
26 add_subdirectory(zzip)
27
28 if(ZZIPWRAP)
29 add_subdirectory(zzipwrap)
30 endif()
31
32 if(ZZIPSDL)
33 add_subdirectory(SDL)
34 endif()
35
36 if(ZZIPBINS)
37 add_subdirectory(bins)
38 endif()
39
40 if(ZZIPTEST)
41 add_subdirectory(test)
42 endif()
43
44 if(ZZIPDOCS)
45 add_subdirectory(docs)
46 endif()