[Cmake] Exporting library dependencies

William A. Hoffman billlist at nycap.rr.com
Fri Jul 30 14:30:11 EDT 2004


If the libraries were exported with full paths, it might
solve the problem.  I recently added some code to the unix
makefiles so that if a full path to a library was given it
would be used in the depend information for the target linking
the library.  

-Bill


At 02:11 PM 7/30/2004, Amitha Perera wrote:
>Brad King wrote:
>> Right now this is handled in VTK and ITK by setting a
>> VTK_LIBRARY_DIRS variable in VTKConfig.cmake and doing a
>> LINK_DIRECTORIES(${VTK_LIBRARY_DIRS}) in UseVTK.cmake.
>
>Exactly. This allows the linker to function well, but not the
>dependencies. I'm not sure I communicated my basic point clearly in my
>previous email, so I'll repeat. Suppose an exectuable E in the second
>tree depends on a library L in the first tree. If we rebuild L and do
>"make" on E, E should rebuild. Currently, it will not.
>
>> Having a more automated solution would be great if you can come up
>> with one.
>
>I think the solution involves to export the *_CMAKE_PATH
>variables. I'll explore this.
>
>> I believe that targets do know where they will be installed, so it
>> is possible to automate this for both the build tree and install
>> tree.
>
>I have never used the install feature of CMake, so I don't know what
>is involved there. I'll look into the uninstall way first, and then
>look into the install way.
>
>Amitha.
>_______________________________________________
>Cmake mailing list
>Cmake at www.cmake.org
>http://www.cmake.org/mailman/listinfo/cmake 



More information about the Cmake mailing list