aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2024-01-25 23:34:41 -0800
committerGarrett D'Amore <garrett@damore.org>2024-01-27 16:54:54 -0800
commitd6f0c13355199173dd7a2957dc2bae54bb5d85c3 (patch)
tree92d70a3bfcad8896714dcbaa0930a21dd04605d1 /CMakeLists.txt
parent463b2fe68fb55898d66a7d89064ad76c67083501 (diff)
downloadnng-d6f0c13355199173dd7a2957dc2bae54bb5d85c3.tar.gz
nng-d6f0c13355199173dd7a2957dc2bae54bb5d85c3.tar.bz2
nng-d6f0c13355199173dd7a2957dc2bae54bb5d85c3.zip
New CMAKE option NNG_ENABLE_COMPAT (defaults ON)
This option allows the compatibility code to be elided from the build. This saves build time, and eliminates bloat from a static library when used strictly in native NNG mode.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt3
1 files changed, 3 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7fe8f712..d828d15e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -96,6 +96,9 @@ target_compile_definitions(nng_private INTERFACE NNG_PRIVATE)
if (NNG_ELIDE_DEPRECATED)
target_compile_definitions(nng PRIVATE NNG_ELIDE_DEPRECATED)
endif()
+if (NNG_ENABLE_COMPAT)
+ target_compile_definitions(nng PRIVATE NNG_ENABLE_COMPAT)
+endif()
# We can use rlimit to configure the stack size for systems