List sublibraries automatically & create a top target that depends on everything
This commit is contained in:
parent
549f2ada41
commit
a2b1d90c48
2 changed files with 18 additions and 5 deletions
|
|
@ -11,3 +11,7 @@ if(PSEMEK_BUILD_TYPE STREQUAL "DEBUG")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_subdirectory(libs)
|
add_subdirectory(libs)
|
||||||
|
|
||||||
|
add_library(psemek todo.md)
|
||||||
|
target_link_libraries(psemek INTERFACE ${PSEMEK_LIBRARIES})
|
||||||
|
set_target_properties(psemek PROPERTIES LINKER_LANGUAGE CXX)
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,14 @@
|
||||||
add_subdirectory(util)
|
set(PSEMEK_LIBRARIES
|
||||||
add_subdirectory(geom)
|
util
|
||||||
add_subdirectory(cg)
|
geom
|
||||||
add_subdirectory(pcg)
|
cg
|
||||||
add_subdirectory(gfx)
|
pcg
|
||||||
|
gfx
|
||||||
|
)
|
||||||
|
|
||||||
|
file(GLOB PSEMEK_LIBRARIES RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" "${CMAKE_CURRENT_SOURCE_DIR}/*")
|
||||||
|
list(REMOVE_ITEM PSEMEK_LIBRARIES "CMakeLists.txt")
|
||||||
|
|
||||||
|
foreach(lib ${PSEMEK_LIBRARIES})
|
||||||
|
add_subdirectory(${lib})
|
||||||
|
endforeach()
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue