Refactored CMakeLists.txt
* new pip_module() macro * fixed exports * automatic gather all exports and pass them to Doxygen and PICodeParser
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
include(DownloadGTest)
|
||||
|
||||
macro(pip_test NAME LIBS)
|
||||
gather_src("${NAME}" CPP_${NAME}_TEST _T_H _T_PH)
|
||||
file(GLOB _CPPS "${NAME}/*.cpp")
|
||||
file(GLOB _HDRS "${NAME}/*.h")
|
||||
set(_target pip_${NAME}_test)
|
||||
add_executable(${_target} ${CPP_${NAME}_TEST})
|
||||
add_executable(${_target} ${_CPPS} ${_HDRS})
|
||||
target_link_libraries(${_target} pip ${LIBS} gtest_main gmock_main)
|
||||
add_test(NAME ${_target} COMMAND tests)
|
||||
add_custom_target(${_target}_perform ALL COMMAND ${_target})
|
||||
|
||||
Reference in New Issue
Block a user