<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2900.5848" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009>Hi,</SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009><BR>I think I found some information on my own, about
this. </SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009><A
href="http://cmake.org/Wiki/CMake_RPATH_handling">http://cmake.org/Wiki/CMake_RPATH_handling</A></SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009>Which explains the behaviour I observed (but didn't
expect) </SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT><FONT face=Arial color=#0000ff
size=2><SPAN class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009>However, what is the recommended way for installing
one's own itk-based programs and the itk-libraries for others on the system to
use? </SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009>It seems I should either:</SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009>1 Have any itk users insert a LD_LIBRARY_PATH pointing
to ...lib/InsightToolKit</SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009>2 Use full RPATH (vulnerable to assorted
filesystem layout change problems ) </SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009>3 install ITK libraries in /usr/local/... (but that's
not good for the cluster, /usr/local is not central but local to each node here)
</SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009>Any suggestions? </SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009>I am veering towards option 1 combined with
'modules' <A
href="http://modules.sourceforge.net/">http://modules.sourceforge.net/</A> </SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT><FONT face=Arial color=#0000ff
size=2><SPAN class=790261111-10092009></SPAN></FONT><FONT face=Arial
color=#0000ff size=2><SPAN class=790261111-10092009></SPAN></FONT><FONT
face=Arial color=#0000ff size=2><SPAN
class=790261111-10092009></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><BR></DIV>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> cmake-bounces@cmake.org
[mailto:cmake-bounces@cmake.org] <B>On Behalf Of </B>Atwood, Robert
(DLSLtd,RAL,DIA)<BR><B>Sent:</B> 08 September 2009 16:25<BR><B>To:</B>
cmake@cmake.org<BR><B>Subject:</B> [CMake] INSTALL query
(itk,cmake)<BR></FONT><BR></DIV>
<DIV></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2>Hi,</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial size=2>I finally attempted
to enable INSTALL support in my CMakeLists file for a project that uses
ITK.</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial size=2>However when I
install by this method the program loses the location of the ITK
libraries.</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2>__________________</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial size=2> which
itk_flop<BR>/dls/i12/software/64/bin/itk_flop</FONT></SPAN></DIV><SPAN
class=524161515-08092009>
<DIV><FONT face=Arial><BR><FONT size=2></FONT></FONT> </DIV>
<DIV><FONT face=Arial size=2> itk_flop<BR>itk_flop: error while loading
shared libraries: libITKCommon.so.3.15: cannot open shared object file: No such
file or directory<BR><SPAN class=524161515-08092009></SPAN>_<SPAN
class=524161515-08092009>____________________</SPAN><BR></FONT></DIV></SPAN>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial size=2>Simply copying the
built project files into the installation destination does not lose the
location. </FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2>________________</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial size=2>cp itk_flop
/dls/i12/software/64/bin/</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial size=2> which
itk_flop<BR>/dls/i12/software/64/bin/itk_flop<BR></FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2> itk_flop<BR>Little program to use itk reading and writing<BR>to
convert file formats<BR>including reading a series of files and writing an
orthogonal series</FONT></SPAN></DIV>
<DIV> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial size=2>Series Usage:
itk_flop inbasename.xxx first last
outbasename.yyy<BR>______________________</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial size=2>What should be done?
I'd like other users to be able to issue 'make install' and have it
work for them.</FONT></SPAN></DIV><SPAN class=524161515-08092009>
<DIV><BR> </DIV>
<DIV><BR><FONT face=Arial><FONT size=2>I used these lines in my CMakeLists.txt
file<SPAN class=524161515-08092009>, as suggested by <A
href="http://www.itk.org/Wiki/CMake:Install_Commands">http://www.itk.org/Wiki/CMake:Install_Commands</A></SPAN></FONT></FONT></DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN
class=524161515-08092009></SPAN></FONT></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2>SET(CMAKE_INSTALL_PREFIX "/dls/i12/software/64" CACHE PATH "Local
installation<BR>prefix" FORCE )<BR></FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2>...</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2> </DIV></FONT></SPAN>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2> INSTALL(TARGETS scanpar itk_flop itk_series_readwrite
itk_parallel_project itk_readwrite_series<BR> RUNTIME
DESTINATION bin<BR> LIBRARY DESTINATION
lib<BR> ARCHIVE DESTINATION lib)<BR></FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial size=2>In ccmake I've
selected the followign, which is indeed the location of
InsightToolkit</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2> ITK_DIR
/dls/i12/software/64/lib/InsightToolkit<BR></FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2>Thanks,<BR>Robert</FONT></SPAN></DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=524161515-08092009></SPAN><SPAN class=524161515-08092009><FONT
face=Arial size=2> </DIV></FONT></SPAN><BR>
<P align=justify>This e-mail and any attachments may contain confidential,
copyright and or privileged material, and are for the use of the intended
addressee only. If you are not the intended addressee or an authorised recipient
of the addressee please notify us of receipt by returning the e-mail and do not
use, copy, retain, distribute or disclose the information in or attached to the
e-mail.<BR>Any opinions expressed within this e-mail are those of the individual
and not necessarily of Diamond Light Source Ltd. <BR>Diamond Light Source Ltd.
cannot guarantee that this e-mail or any attachments are free from viruses and
we cannot accept liability for any damage which you may sustain as a result of
software viruses which may be transmitted in or with the message.<BR>Diamond
Light Source Limited (company no. 4375679). Registered in England and Wales with
its registered office at Diamond House, Harwell Science and Innovation Campus,
Didcot, Oxfordshire, OX11 0DE, United Kingdom<BR> </P><BR>
<br><P align=justify>This e-mail and any attachments may contain confidential, copyright and or privileged material, and are for the use of the intended addressee only. If you are not the intended addressee or an authorised recipient of the addressee please notify us of receipt by returning the e-mail and do not use, copy, retain, distribute or disclose the information in or attached to the e-mail.<BR>Any opinions expressed within this e-mail are those of the individual and not necessarily of Diamond Light Source Ltd. <BR>Diamond Light Source Ltd. cannot guarantee that this e-mail or any attachments are free from viruses and we cannot accept liability for any damage which you may sustain as a result of software viruses which may be transmitted in or with the message.<BR>Diamond Light Source Limited (company no. 4375679). Registered in England and Wales with its registered office at Diamond House, Harwell Science and Innovation Campus, Didcot, Oxfordshire, OX11 0DE, United Kingdom<BR> </P>
<br></BODY></HTML>