From: James Turner Date: Tue, 29 Nov 2011 10:24:33 +0000 (+0000) Subject: Fixes for linking with shared SimGear. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=f054f156934150ef132317825b5964774a5b472c;p=flightgear.git Fixes for linking with shared SimGear. --- diff --git a/CMakeModules/FindSimGear.cmake b/CMakeModules/FindSimGear.cmake index e1becbea2..3d7b271bb 100644 --- a/CMakeModules/FindSimGear.cmake +++ b/CMakeModules/FindSimGear.cmake @@ -116,6 +116,7 @@ if(SIMGEAR_SHARED) set(SIMGEAR_CORE_LIBRARIES ${SIMGEAR_SHARED_CORE_LIBRARY}) set(SIMGEAR_LIBRARIES ${SIMGEAR_SHARED_SCENE_LIBRARY} ${SIMGEAR_SHARED_CORE_LIBRARY}) set(SIMGEAR_CORE_LIBRARY_DEPENDENCIES "") + set(SIMGEAR_SCENE_LIBRARY_DEPENDENCIES "") else(SIMGEAR_SHARED) @@ -127,17 +128,13 @@ else(SIMGEAR_SHARED) # linked in, and hence ability to link when using a traditional # linker such as GNU ld on Linux set(comps - tsync environment nasal bucket - bvh - util route timing io serial - sound math props structure @@ -149,12 +146,16 @@ else(SIMGEAR_SHARED) ) set(scene_comps + tsync ephem sky material tgdb model - screen) + screen + bvh + util + sound) foreach(component ${comps}) find_sg_component(${component} SIMGEAR_CORE_LIBRARIES) @@ -171,6 +172,11 @@ else(SIMGEAR_SHARED) ${CMAKE_THREAD_LIBS_INIT} ${ZLIB_LIBRARY}) + set(SIMGEAR_SCENE_LIBRARY_DEPENDENCIES + ${ALUT_LIBRARY} + ${OPENAL_LIBRARY} + ${LIBSVN_LIBRARIES}) + if(WIN32) list(APPEND SIMGEAR_CORE_LIBRARY_DEPENDENCIES ws2_32.lib) endif(WIN32) diff --git a/src/Instrumentation/HUD/HUD_runway.cxx b/src/Instrumentation/HUD/HUD_runway.cxx index 6f05a706a..42f2e44ac 100644 --- a/src/Instrumentation/HUD/HUD_runway.cxx +++ b/src/Instrumentation/HUD/HUD_runway.cxx @@ -25,7 +25,7 @@ #include #include -#include +#include #include
#include diff --git a/src/Main/CMakeLists.txt b/src/Main/CMakeLists.txt index e3e06aa8c..18bb7f9dc 100644 --- a/src/Main/CMakeLists.txt +++ b/src/Main/CMakeLists.txt @@ -73,14 +73,12 @@ target_link_libraries(fgfs ${FG_LIBS} ${SIMGEAR_LIBRARIES} ${OPENSCENEGRAPH_LIBRARIES} - ${ALUT_LIBRARY} - ${OPENAL_LIBRARY} ${OPENGL_LIBRARIES} ${PLIB_LIBRARIES} ${JPEG_LIBRARY} - ${LIBSVN_LIBRARIES} ${HLA_LIBRARIES} ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} + ${SIMGEAR_SCENE_LIBRARY_DEPENDENCIES} ${PLATFORM_LIBS} ) diff --git a/utils/GPSsmooth/CMakeLists.txt b/utils/GPSsmooth/CMakeLists.txt index ecfdde70f..47bc1d54f 100644 --- a/utils/GPSsmooth/CMakeLists.txt +++ b/utils/GPSsmooth/CMakeLists.txt @@ -13,6 +13,7 @@ target_link_libraries(GPSsmooth ${PLIB_SG_LIBRARY} ${PLIB_UL_LIBRARY} ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} + ${ZLIB_LIBRARY} ${WINMM_LIBRARY} ) @@ -21,6 +22,7 @@ target_link_libraries(MIDGsmooth ${PLIB_SG_LIBRARY} ${PLIB_UL_LIBRARY} ${WINMM_LIBRARY} + ${ZLIB_LIBRARY} ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} ) @@ -29,6 +31,7 @@ target_link_libraries(UGsmooth ${PLIB_SG_LIBRARY} ${PLIB_UL_LIBRARY} ${WINMM_LIBRARY} + ${ZLIB_LIBRARY} ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} )