1
0
Fork 0

Fixes for linking with shared SimGear.

This commit is contained in:
James Turner 2011-11-29 10:24:33 +00:00
parent 62810e3f9a
commit f054f15693
4 changed files with 16 additions and 9 deletions

View file

@ -116,6 +116,7 @@ if(SIMGEAR_SHARED)
set(SIMGEAR_CORE_LIBRARIES ${SIMGEAR_SHARED_CORE_LIBRARY}) set(SIMGEAR_CORE_LIBRARIES ${SIMGEAR_SHARED_CORE_LIBRARY})
set(SIMGEAR_LIBRARIES ${SIMGEAR_SHARED_SCENE_LIBRARY} ${SIMGEAR_SHARED_CORE_LIBRARY}) set(SIMGEAR_LIBRARIES ${SIMGEAR_SHARED_SCENE_LIBRARY} ${SIMGEAR_SHARED_CORE_LIBRARY})
set(SIMGEAR_CORE_LIBRARY_DEPENDENCIES "") set(SIMGEAR_CORE_LIBRARY_DEPENDENCIES "")
set(SIMGEAR_SCENE_LIBRARY_DEPENDENCIES "")
else(SIMGEAR_SHARED) else(SIMGEAR_SHARED)
@ -127,17 +128,13 @@ else(SIMGEAR_SHARED)
# linked in, and hence ability to link when using a traditional # linked in, and hence ability to link when using a traditional
# linker such as GNU ld on Linux # linker such as GNU ld on Linux
set(comps set(comps
tsync
environment environment
nasal nasal
bucket bucket
bvh
util
route route
timing timing
io io
serial serial
sound
math math
props props
structure structure
@ -149,12 +146,16 @@ else(SIMGEAR_SHARED)
) )
set(scene_comps set(scene_comps
tsync
ephem ephem
sky sky
material material
tgdb tgdb
model model
screen) screen
bvh
util
sound)
foreach(component ${comps}) foreach(component ${comps})
find_sg_component(${component} SIMGEAR_CORE_LIBRARIES) find_sg_component(${component} SIMGEAR_CORE_LIBRARIES)
@ -171,6 +172,11 @@ else(SIMGEAR_SHARED)
${CMAKE_THREAD_LIBS_INIT} ${CMAKE_THREAD_LIBS_INIT}
${ZLIB_LIBRARY}) ${ZLIB_LIBRARY})
set(SIMGEAR_SCENE_LIBRARY_DEPENDENCIES
${ALUT_LIBRARY}
${OPENAL_LIBRARY}
${LIBSVN_LIBRARIES})
if(WIN32) if(WIN32)
list(APPEND SIMGEAR_CORE_LIBRARY_DEPENDENCIES ws2_32.lib) list(APPEND SIMGEAR_CORE_LIBRARY_DEPENDENCIES ws2_32.lib)
endif(WIN32) endif(WIN32)

View file

@ -25,7 +25,7 @@
#include <simgear/compiler.h> #include <simgear/compiler.h>
#include <simgear/math/sg_geodesy.hxx> #include <simgear/math/sg_geodesy.hxx>
#include <simgear/math/project.hxx> #include <simgear/scene/util/project.hxx>
#include <Main/globals.hxx> #include <Main/globals.hxx>
#include <Scenery/scenery.hxx> #include <Scenery/scenery.hxx>

View file

@ -73,14 +73,12 @@ target_link_libraries(fgfs
${FG_LIBS} ${FG_LIBS}
${SIMGEAR_LIBRARIES} ${SIMGEAR_LIBRARIES}
${OPENSCENEGRAPH_LIBRARIES} ${OPENSCENEGRAPH_LIBRARIES}
${ALUT_LIBRARY}
${OPENAL_LIBRARY}
${OPENGL_LIBRARIES} ${OPENGL_LIBRARIES}
${PLIB_LIBRARIES} ${PLIB_LIBRARIES}
${JPEG_LIBRARY} ${JPEG_LIBRARY}
${LIBSVN_LIBRARIES}
${HLA_LIBRARIES} ${HLA_LIBRARIES}
${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES}
${SIMGEAR_SCENE_LIBRARY_DEPENDENCIES}
${PLATFORM_LIBS} ${PLATFORM_LIBS}
) )

View file

@ -13,6 +13,7 @@ target_link_libraries(GPSsmooth
${PLIB_SG_LIBRARY} ${PLIB_SG_LIBRARY}
${PLIB_UL_LIBRARY} ${PLIB_UL_LIBRARY}
${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES}
${ZLIB_LIBRARY}
${WINMM_LIBRARY} ${WINMM_LIBRARY}
) )
@ -21,6 +22,7 @@ target_link_libraries(MIDGsmooth
${PLIB_SG_LIBRARY} ${PLIB_SG_LIBRARY}
${PLIB_UL_LIBRARY} ${PLIB_UL_LIBRARY}
${WINMM_LIBRARY} ${WINMM_LIBRARY}
${ZLIB_LIBRARY}
${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES}
) )
@ -29,6 +31,7 @@ target_link_libraries(UGsmooth
${PLIB_SG_LIBRARY} ${PLIB_SG_LIBRARY}
${PLIB_UL_LIBRARY} ${PLIB_UL_LIBRARY}
${WINMM_LIBRARY} ${WINMM_LIBRARY}
${ZLIB_LIBRARY}
${SIMGEAR_CORE_LIBRARY_DEPENDENCIES} ${SIMGEAR_CORE_LIBRARY_DEPENDENCIES}
) )