|
|
|
@ -10,7 +10,7 @@ include(GNUInstallDirs)
|
|
|
|
|
|
|
|
|
|
option(WITH_HARDENING "Enable hardening options" ON) |
|
|
|
|
option(WITH_TOOLS "Build library management tools" ON) |
|
|
|
|
set(SAMPLER "magick" CACHE STRING "Library for sampling") |
|
|
|
|
set(SIMDB_SAMPLER "magick" CACHE STRING "Library for sampling") |
|
|
|
|
|
|
|
|
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -pedantic -std=c99") |
|
|
|
|
add_definitions("-D_XOPEN_SOURCE=500") |
|
|
|
@ -21,12 +21,12 @@ if (WITH_HARDENING)
|
|
|
|
|
add_definitions("-D_FORTIFY_SOURCE=2") |
|
|
|
|
endif () |
|
|
|
|
|
|
|
|
|
if (${SAMPLER} STREQUAL "dummy") |
|
|
|
|
set(SAMPLER "dummy") |
|
|
|
|
elseif (${SAMPLER} STREQUAL "random") |
|
|
|
|
set(SAMPLER "random") |
|
|
|
|
if (${SIMDB_SAMPLER} STREQUAL "dummy") |
|
|
|
|
set(SIMDB_SAMPLER "dummy") |
|
|
|
|
elseif (${SIMDB_SAMPLER} STREQUAL "random") |
|
|
|
|
set(SIMDB_SAMPLER "random") |
|
|
|
|
else () |
|
|
|
|
set(SAMPLER "magick") |
|
|
|
|
set(SIMDB_SAMPLER "magick") |
|
|
|
|
endif () |
|
|
|
|
|
|
|
|
|
message(STATUS "Project : ${CNAME} v${VERSION}") |
|
|
|
@ -41,7 +41,7 @@ message(STATUS "Build type : ${CMAKE_BUILD_TYPE}")
|
|
|
|
|
message(STATUS "Options:") |
|
|
|
|
message(STATUS "- WITH_HARDENING : ${WITH_HARDENING}") |
|
|
|
|
message(STATUS "- WITH_TOOLS : ${WITH_TOOLS}") |
|
|
|
|
message(STATUS "- SAMPLER : ${SAMPLER}") |
|
|
|
|
message(STATUS "- SIMDB_SAMPLER : ${SIMDB_SAMPLER}") |
|
|
|
|
|
|
|
|
|
add_subdirectory("src") |
|
|
|
|
add_subdirectory("tests") |
|
|
|
|