X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FMain%2FCMakeLists.txt;h=338a9f6d4fbaad94f3d0b81e36fc5071889d473b;hb=52e5a9abe83882ca946429f7d8e71894d5852d8f;hp=73c899b6c7cf519481421e5889d5f88565c469c7;hpb=c8e1433a5c5915428f38c87776f1e96f63429974;p=flightgear.git diff --git a/src/Main/CMakeLists.txt b/src/Main/CMakeLists.txt index 73c899b6c..338a9f6d4 100644 --- a/src/Main/CMakeLists.txt +++ b/src/Main/CMakeLists.txt @@ -14,12 +14,15 @@ set(SOURCES fg_io.cxx fg_os_common.cxx fg_props.cxx + FGInterpolator.cxx globals.cxx locale.cxx logger.cxx main.cxx options.cxx util.cxx + positioninit.cxx + subsystemFactory.cxx ${RESOURCE_FILE} ) @@ -28,12 +31,15 @@ set(HEADERS fg_init.hxx fg_io.hxx fg_props.hxx + FGInterpolator.hxx globals.hxx locale.hxx logger.hxx main.hxx options.hxx util.hxx + positioninit.hxx + subsystemFactory.hxx ) get_property(FG_SOURCES GLOBAL PROPERTY FG_SOURCES) @@ -41,6 +47,26 @@ get_property(FG_HEADERS GLOBAL PROPERTY FG_HEADERS) link_directories ( ${Boost_LIBRARY_DIRS} ) +get_property(FG_GROUPS_C GLOBAL PROPERTY FG_GROUPS_C) +string(REPLACE "@" ";" groups ${FG_GROUPS_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_H GLOBAL PROPERTY FG_GROUPS_H) +string(REPLACE "@" ";" groups ${FG_GROUPS_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() + +source_group("Main\\Headers" FILES ${HEADERS}) +source_group("Main\\Sources" FILES ${SOURCES}) add_executable(fgfs ${SOURCES} ${FG_SOURCES} ${FG_HEADERS} ${HEADERS}) get_property(FG_LIBS GLOBAL PROPERTY FG_LIBS) @@ -49,9 +75,6 @@ get_property(FG_LIBS GLOBAL PROPERTY FG_LIBS) #message(STATUS "SG libs ${SIMGEAR_LIBRARIES}") if(RTI_FOUND) - find_sg_component(hla SIMGEAR_LIBRARIES) - find_sg_component(rti13 SIMGEAR_LIBRARIES) - find_sg_component(rti SIMGEAR_LIBRARIES) set(HLA_LIBRARIES ${RTI_LIBRARIES}) else() set(HLA_LIBRARIES "") @@ -63,8 +86,16 @@ if(ENABLE_JSBSIM) target_link_libraries(fgfs JSBSim) endif() +if(ENABLE_IAX) + target_link_libraries(fgfs iaxclient_lib ${OPENAL_LIBRARY}) +endif() +if(FG_HAVE_GPERFTOOLS) + include_directories(${GooglePerfTools_INCLUDE_DIR}) + target_link_libraries(fgfs ${GooglePerfTools_LIBRARIES}) +endif() target_link_libraries(fgfs + ${SQLITE3_LIBRARY} ${SIMGEAR_LIBRARIES} ${OPENSCENEGRAPH_LIBRARIES} ${OPENGL_LIBRARIES} @@ -75,18 +106,18 @@ target_link_libraries(fgfs ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} ${SIMGEAR_SCENE_LIBRARY_DEPENDENCIES} ${PLATFORM_LIBS} - ShivaVG ) install(TARGETS fgfs RUNTIME DESTINATION bin) -add_executable(metar metar_main.cxx) +if(ENABLE_METAR) + add_executable(metar metar_main.cxx) + target_link_libraries(metar + ${SIMGEAR_LIBRARIES} + ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} + ${SIMGEAR_SCENE_LIBRARY_DEPENDENCIES} + ${PLATFORM_LIBS} + ) -target_link_libraries(metar - ${SIMGEAR_LIBRARIES} - ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} - ${SIMGEAR_SCENE_LIBRARY_DEPENDENCIES} - ${PLATFORM_LIBS} -) - -install(TARGETS metar RUNTIME DESTINATION bin) + install(TARGETS metar RUNTIME DESTINATION bin) +endif()