Library not loaded: libiomp5.dylib

Library not loaded: libiomp5.dylib

Hello,

I recently installed the newest intel fortran compiler on my macbook pro (a few days ago). My code compiles fine, but when i go to run the code i get the following output:

dyld: Library not loaded: libiomp5.dylib
Referenced from: /Users/matthewturner/Desktop/School/Intro to Research/FORTRAN/hello
Reason: image not found

I have set theDYLD_LIBRARY_PATH to the location of "libiomp5.dylib" using the following command:

export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/opt/intel/Compiler/11.1/058/lib

however i still get the same "Library not loaded" error message.

Does anybody have any suggestions on how to resolve this issue?

Thanks in advance

4 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

What is the output of the command below say?

otool -L /Users/matthewturner/Desktop/School/Intro to Research/FORTRAN/hello

Source-ingthe ifortvars environment script before compiling sets DYLD_LIBRARY_PATH accordingly so you should not have to set it explicitly.

Quoting - Kevin Davis (Intel)

What is the output of the command below say?

otool -L /Users/matthewturner/Desktop/School/Intro to Research/FORTRAN/hello

Source-ingthe ifortvars environment script before compiling sets DYLD_LIBRARY_PATH accordingly so you should not have to set it explicitly.

Prior to reading your response, I realized i needed to put the "export DYLD_LIBRARY_PATH=...." into my bashrc file. After doing this, everything works fine now.

But just incase you still want to know the output from the otool -L command, here it is:

/Users/matthewturner/Desktop/School/Intro to Research/fortran/hello:
libiomp5.dylib (compatibility version 5.0.0, current version 5.0.0)
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libmx.A.dylib (compatibility version 1.0.0, current version 292.4.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.4)

Glad you resolved this. Interest in otool was just to ensure the absence of absolute path to the library as such makes DYLD_LIBRARY_PATH immaterial in locating the lib.

Leave a Comment

Please sign in to add a comment. Not a member? Join today