[ITK] ITK ImageFileReader Example Library Not Loaded

Jeanna S. jeannasheen at gmail.com
Sun Aug 7 19:16:59 EDT 2016


Hello,

I have already found a solution to my problem here
<http://public.kitware.com/pipermail/insight-users/2009-April/029807.html>.
It seems all I have to do is type "export DYLD_LIBRARY_PATH=" followed by
the install path in the Terminal.

On Sat, Aug 6, 2016 at 8:53 PM, Jeanna S. <jeannasheen at gmail.com> wrote:

> Hello,
>
> I am trying to run the ITK ImageFileReader example (here
> <https://itk.org/Wiki/ITK/Examples/IO/ImageFileReader>). CMake can
> successfully configure and generate the executable, but when I try to run
> the executable, I get the following error:
>
> dyld: Library not loaded: libvtkDomainsChemistryOpenGL2-7.0.1.dylib
>
>   Referenced from: /Users/JJ/Desktop/ITKstuffs/ImageFileReader/build/
> ImageFileReader.app/Contents/MacOS/./ImageFileReader
>
>   Reason: image not found
>
> Trace/BPT trap: 5
>
> A search of the files on my computer reveals that
> libvtkDomainsChemistryOpenGL2-7.0.1.dylib is in
> /Users/JJ/Desktop/ITKstuffs/Install/vtk/lib.
>
> I can open the executable file generated by CMake in my text editor, and I
> think I found where libvtkDomainsChemistryOpenGL2-7.0.1.dylib is being
> referenced. There are 2 lines that state:
>
> 0 /usr/lib/libz.1.dylib
>
> H libvtkDomainsChemistryOpenGL2-7.0.1.dylib
>
> I do not know why the program is looking for the libraries in user/lib,
> because when I configured and generated the code in CMake I changed the CMAKE_INSTALL_PREFIX
> to /Users/JJ/Desktop/ITKstuffs/Install.
>
> If anyone has any suggestions on how to fix this problem, they would be
> much appreciated.
>
> I would also like to know where to put the image file to be read and how
> to tell the program where the image to be read is (e.g. do I pass the file
> name and path when I run the executable?).
>
> Thanks in advance.
>



-- 
when the rich wage war, it's the poor who die
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/community/attachments/20160807/a9b0d256/attachment.html>


More information about the Community mailing list