<div class="gmail_quote">On Sat, Feb 14, 2009 at 9:35 AM, Dupi <span dir="ltr"><<a href="mailto:nefreyu@gmail.com" target="_blank">nefreyu@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div link="blue" vlink="purple" lang="SK">
<div>
<p><span lang="EN-US">Hi all.</span></p>
<p><span lang="EN-US">I have problem with adding ode library to
the static library in Visual Studio 2008. My project name is oxygen and it is
depend from ODE library version 0.9 (<a href="http://downloads.sourceforge.net/opende/ode-win32-0.9.zip?modtime=1192176753&big_mirror=0" target="_blank">http://downloads.sourceforge.net/opende/ode-win32-0.9.zip?modtime=1192176753&big_mirror=0</a>
). CMakeLists.txt file for oxygen include following lines:</span></p>
<p><span lang="EN-US"># include all headers of project (.h)</span></p>
<p><span lang="EN-US">set(oxygen_LIB_HDRS …….. )</span></p>
<p><span lang="EN-US">#include all source files of project
(.cpp)</span></p>
<p><span lang="EN-US">set(oxygen_LIB_SRCS ……..)</span></p>
<p><span lang="EN-US">#include directory of ODE library. Value
ODE_INCLUDE_DIR is C:/library/ode/include. Also this value is added into VS
project (Project properties -> Configuration Properties
->C/C++->General->Additional Include Directories)</span></p>
<p><span lang="EN-US">include_directories(${ODE_INCLUDE_DIR})</span></p>
<p><span lang="EN-US">#create static library oxygen.lib</span></p>
<p><span lang="EN-US">add_library(oxygen STATIC
${oxygen_LIB_SRCS} ${oxygen_LIB_HDRS})</span></p>
<p><span lang="EN-US">#add ode.lib to the oxygen. Value
ODE_LIBRARY is C:/library/ode/lib/releaselib/ode.lib. But this value is not
added into VS project (Project properties -> Configuration Properties
->Librarian->General->Additional Dependencies)</span></p>
<p><span lang="EN-US">target_link_libraries(oxygen
${ODE_LIBRARY})</span></p>
<p><span lang="EN-US"> </span></p>
<p><span lang="EN-US">If I change project from static library
(lib) to the dynamic library (dll) (change values add_library to the (oxygen
SHARED ${oxygen_LIB_SRCS} ${oxygen_LIB_HDRS})), value ODE_LIBRARY
(C:/library/ode/lib/releaselib/ode.lib) is added into VS Project. I finding
solution about one week but still nothing. </span></p>
<p><span lang="EN-US">Thank you for every advice.</span></p></div></div></blockquote><div>This came up on the mailing list very recently. You might want to have a look at this thread:<br><a href="http://www.cmake.org/pipermail/cmake/2009-February/026964.html">http://www.cmake.org/pipermail/cmake/2009-February/026964.html</a><br>
<br></div></div><br>-- <br>Philip Lowman<br>