summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorAzamat H. Hackimov <azamat.hackimov@gmail.com>2017-01-05 01:12:16 +0500
committerAzamat H. Hackimov <azamat.hackimov@gmail.com>2017-01-06 17:17:10 +0500
commitc9c18fff2fd8b3d0bef0120fe3db3b6ab0beeb9b (patch)
treebc2450b78f0afeb62feb64d5457f85d9536b5013 /CMakeLists.txt
parent7031efcb5fc577dc70f3188ce1c46bf894b1e48a (diff)
Make shared and static libraries optional
Now you can enable/disable compilation and installation targets for shared and static libraries via -DCMARK_SHARED=ON/OFF and -DCMARK_STATIC=ON/OFF
Diffstat (limited to 'CMakeLists.txt')
-rwxr-xr-xCMakeLists.txt4
1 files changed, 3 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 328f74c..4e60fd5 100755
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -22,9 +22,11 @@ set(PROJECT_VERSION_PATCH 1)
set(PROJECT_VERSION ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH} )
option(CMARK_TESTS "Build cmark tests and enable testing" ON)
+option(CMARK_STATIC "Build static libcmark library" ON)
+option(CMARK_SHARED "Build shared libcmark library" ON)
add_subdirectory(src)
-if(CMARK_TESTS)
+if(CMARK_TESTS AND CMARK_SHARED)
add_subdirectory(api_test)
endif()
add_subdirectory(man)