On 03/23/2011 05:26 PM, Chris Volpe ARA/SED wrote: > Jc- > > Thanks for the suggestions, but it's not clear if your suggestions are > general suggestions, or if they actually address the problem I'm > experiencing. Moreover, the problems that your suggestions claim to solve > seem to be problems that I am not experiencing.
[...] > Also: > Moreover, in your example, it seems the command "LINK_DIRECTORIES" is > missing. Indeed, you should add the following command before calling > ADD_LIBRARY(FeatureViewer ...): > > LINK_DIRECTORIES(${VTK_LIBRARY_DIRS}) > What problem does "LINK_DIRECTORIES" solve? Note that I have no problem > building FeatureViewer: It finds the VTK libraries just fine without > LINK_DIRECTORIES. Again, the TestDriver application builds and runs just fine > if I manually remove the references to vtk*.lib in its project settings. LINK_DIRECTORIES() can be subtly dangerous, see [1], so it should not be used if it's avoidable. AFAICS, VTK uses imported targets for its libraries, i.e. with full paths in the libraries' IMPORTED_LOCATION properties, so there shouldn't be a need to use LINK_DIRECTORIES() w.r.t. VTK. Regards, Michael [1] http://www.mail-archive.com/cmake@cmake.org/msg33519.html _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake