cmake: add USE_TRACE option (default OFF)
@@ -9,6 +9,7 @@ find_package(OpenSSL)
option(USE_OPENSSL "Enable OpenSSL" ${OPENSSL_FOUND})
option(USE_UNIXSOCK "Enable Unix Domain Sockets" ON)
+option(USE_TRACE "Enable Tracing helpers" OFF)
check_symbol_exists("arc4random" "stdlib.h" HAVE_ARC4RANDOM)
if(HAVE_ARC4RANDOM)
@@ -122,6 +123,12 @@ else()
)
endif()
+if(USE_TRACE)
+ list(APPEND RE_DEFINITIONS
+ -DRE_TRACE_ENABLED
+ )
+endif()
+
if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
list(APPEND RE_DEFINITIONS -DDARWIN)
include_directories(/opt/local/include)
