Skip to content
Snippets Groups Projects
Commit 37bc165d authored by olivier stasse's avatar olivier stasse Committed by Valenza Florian
Browse files

[cmake] Supress EXCLUDE_FROM_ALL in unittests if flag COMPILE_UNIT_TESTS is set

parent ac3df696
No related branches found
No related tags found
No related merge requests found
......@@ -2,7 +2,11 @@
# --- MACROS ------------------------------------------------------------------
# --- MACROS ------------------------------------------------------------------
MACRO(ADD_UNIT_TEST NAME PKGS)
ADD_EXECUTABLE(${NAME} EXCLUDE_FROM_ALL ${NAME})
IF (COMPILE_UNIT_TESTS)
ADD_EXECUTABLE(${NAME} ${NAME})
ELSE (COMPILE_UNIT_TESTS)
ADD_EXECUTABLE(${NAME} EXCLUDE_FROM_ALL ${NAME})
ENDIF (COMPILE_UNIT_TESTS)
FOREACH(PKG ${PKGS})
PKG_CONFIG_USE_DEPENDENCY(${NAME} ${PKG})
ENDFOREACH(PKG)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment