mirror of
https://github.com/falcosecurity/falco.git
synced 2025-09-19 17:14:26 +00:00
fix(build): draios debug flags before checking build type
Signed-off-by: Leonardo Di Donato <leodidonato@gmail.com>
This commit is contained in:
committed by
Leo Di Donato
parent
8156c9214c
commit
dc03dbee18
@@ -33,6 +33,10 @@ if(NOT DEFINED FALCO_ETC_DIR)
|
|||||||
set(FALCO_ETC_DIR "/etc/falco")
|
set(FALCO_ETC_DIR "/etc/falco")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(NOT DRAIOS_DEBUG_FLAGS)
|
||||||
|
set(DRAIOS_DEBUG_FLAGS "-D_DEBUG")
|
||||||
|
endif()
|
||||||
|
|
||||||
string(TOLOWER "${CMAKE_BUILD_TYPE}" CMAKE_BUILD_TYPE)
|
string(TOLOWER "${CMAKE_BUILD_TYPE}" CMAKE_BUILD_TYPE)
|
||||||
if (CMAKE_BUILD_TYPE STREQUAL "debug")
|
if (CMAKE_BUILD_TYPE STREQUAL "debug")
|
||||||
set(KBUILD_FLAGS "${DRAIOS_DEBUG_FLAGS} ${DRAIOS_FEATURE_FLAGS}")
|
set(KBUILD_FLAGS "${DRAIOS_DEBUG_FLAGS} ${DRAIOS_FEATURE_FLAGS}")
|
||||||
@@ -41,10 +45,6 @@ else()
|
|||||||
set(KBUILD_FLAGS "${DRAIOS_FEATURE_FLAGS}")
|
set(KBUILD_FLAGS "${DRAIOS_FEATURE_FLAGS}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(NOT DRAIOS_DEBUG_FLAGS)
|
|
||||||
set(DRAIOS_DEBUG_FLAGS "-D_DEBUG")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set(CMAKE_COMMON_FLAGS "-Wall -ggdb ${DRAIOS_FEATURE_FLAGS}")
|
set(CMAKE_COMMON_FLAGS "-Wall -ggdb ${DRAIOS_FEATURE_FLAGS}")
|
||||||
|
|
||||||
if(BUILD_WARNINGS_AS_ERRORS)
|
if(BUILD_WARNINGS_AS_ERRORS)
|
||||||
|
Reference in New Issue
Block a user