[Insight-developers] Installed ITK with shared libraries

Zachary Pincus zpincus at stanford.edu
Fri Feb 24 13:40:50 EST 2006


> Better RPATH support for installed targets built with CMake is  
> provided in the CVS version of CMake, and install_name support on  
> OSX will soon be committed.  We do not want to require such a new  
> CMake though, so for now one should just set CMAKE_SKIP_RPATH when  
> building before doing "make install".  Then the installed binaries  
> will have no rpath/install_name in them at all and one may set [DY] 
> LD_LIBRARY_PATH to use them.
>
> To make this harder to forget we could do in ITK what I did last  
> year in VTK which is to provide a VTK_USE_RPATH option.  If this  
> option is ON then one can run from the build tree but the install  
> target installs nothing and prints a message explaining why.  If  
> the option is OFF then one may install but must set LD_LIBRARY_PATH  
> to run either from the build tree or from the install tree.

Thank you Brad for the suggestions. I think that this would be a good  
start for making sure that people install ITK correctly.

> Avoiding the requirement of setting LD_LIBRARY_PATH for the install  
> tree can be accomplished by using CMake's shared library version  
> support to allow the ITK libs to be installed in PREFIX/lib instead  
> of PREFIX/lib/InsightToolkit.  Then the ld.so.conf on the machine  
> would help the libraries be found.

I'm all for this, too. (On Windows, would the libs also be installed  
into a standard location for the loader to find?) What do the rest of  
the ITK folks think about this?

Zach


More information about the Insight-developers mailing list