macro(simgear_component_common name includePath sourcesList sources headers)
+ set(fc${sourcesList} ${name})
+ set(fh${sourcesList} ${name})
foreach(s ${sources})
set_property(GLOBAL
APPEND PROPERTY ${sourcesList} "${CMAKE_CURRENT_SOURCE_DIR}/${s}")
+ set(fc${sourcesList} "${fc${sourcesList}}#${CMAKE_CURRENT_SOURCE_DIR}/${s}")
endforeach()
foreach(h ${headers})
set_property(GLOBAL
APPEND PROPERTY PUBLIC_HEADERS "${CMAKE_CURRENT_SOURCE_DIR}/${h}")
+ set(fh${sourcesList} "${fh${sourcesList}}#${CMAKE_CURRENT_SOURCE_DIR}/${h}")
endforeach()
+
+ set_property(GLOBAL APPEND PROPERTY FG_GROUPS_${sourcesList}_C "${fc${sourcesList}}@")
+ set_property(GLOBAL APPEND PROPERTY FG_GROUPS_${sourcesList}_H "${fh${sourcesList}}@")
install (FILES ${headers} DESTINATION include/simgear/${includePath})
endmacro()
install(TARGETS SimGearCore LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
else()
message(STATUS "Library building mode: STATIC LIBRARIES")
-
+
+ get_property(FG_GROUPS_CORE_SOURCES_C GLOBAL PROPERTY FG_GROUPS_CORE_SOURCES_C)
+ string(REPLACE "@" ";" groups ${FG_GROUPS_CORE_SOURCES_C} )
+ foreach(g ${groups})
+ string(REPLACE "#" ";" g2 ${g})
+ list(GET g2 0 name)
+ list(REMOVE_AT g2 0)
+ source_group("${name}\\Sources" FILES ${g2})
+ endforeach()
+
+ get_property(FG_GROUPS_CORE_SOURCES_H GLOBAL PROPERTY FG_GROUPS_CORE_SOURCES_H)
+ string(REPLACE "@" ";" groups ${FG_GROUPS_CORE_SOURCES_H} )
+ foreach(g ${groups})
+ string(REPLACE "#" ";" g2 ${g})
+ list(GET g2 0 name)
+ list(REMOVE_AT g2 0)
+ source_group("${name}\\Headers" FILES ${g2})
+ endforeach()
+
add_library(SimGearCore STATIC ${coreSources})
install(TARGETS SimGearCore ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
if(NOT SIMGEAR_HEADLESS)
+ get_property(FG_GROUPS_SCENE_SOURCES_C GLOBAL PROPERTY FG_GROUPS_SCENE_SOURCES_C)
+ string(REPLACE "@" ";" groups ${FG_GROUPS_SCENE_SOURCES_C} )
+ foreach(g ${groups})
+ string(REPLACE "#" ";" g2 ${g})
+ list(GET g2 0 name)
+ list(REMOVE_AT g2 0)
+ source_group("${name}\\Sources" FILES ${g2})
+ endforeach()
+
+ get_property(FG_GROUPS_SCENE_SOURCES_H GLOBAL PROPERTY FG_GROUPS_SCENE_SOURCES_H)
+ string(REPLACE "@" ";" groups ${FG_GROUPS_SCENE_SOURCES_H} )
+ foreach(g ${groups})
+ string(REPLACE "#" ";" g2 ${g})
+ list(GET g2 0 name)
+ list(REMOVE_AT g2 0)
+ source_group("${name}\\Headers" FILES ${g2})
+ endforeach()
+
add_library(SimGearScene STATIC ${sceneSources})
install(TARGETS SimGearScene ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
endif(NOT SIMGEAR_HEADLESS)