diff options
author | Zachary Lund <admin@computerquip.com> | 2020-02-14 19:27:59 -0600 |
---|---|---|
committer | Zachary Lund <admin@computerquip.com> | 2020-02-15 01:20:50 -0600 |
commit | 08984077ea5f2933b3f25a678a1f2be717ae12d0 (patch) | |
tree | 4fce7c0d17be496fd08a27a37974d51363f826b9 /CMakeLists.txt | |
parent | 5f9ebc98618fc1216cde976a2bcf686af119f3ed (diff) | |
download | colm-08984077ea5f2933b3f25a678a1f2be717ae12d0.tar.gz |
add flag to support standalone executables
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index cb910b74..56400bd1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -22,6 +22,16 @@ set(${PROJECT_NAME}_MAKE_INSTALL ON CACHE BOOL set(${PROJECT_NAME}_BUILD_EXAMPLES OFF CACHE BOOL "Set to ON to build examples (default is OFF)") +# Determine stdlib link flags +if (WIN32) + set(DEFAULT_BUILD_STANDALONE ON) +else() + set(DEFAULT_BUILD_STANDALONE OFF) +endif() + +set(BUILD_STANDALONE ${DEFAULT_BUILD_STANDALONE} + CACHE BOOL "Set to ON to make the executables as standalone as possible.") + # Check type size include(CheckTypeSize) check_type_size("int" SIZEOF_INT) |