Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HDF5 issue #3

Open
inti opened this issue Mar 22, 2017 · 2 comments
Open

HDF5 issue #3

inti opened this issue Mar 22, 2017 · 2 comments

Comments

@inti
Copy link

inti commented Mar 22, 2017

Hi after running cmake and make I am getting the following error:

Notice I made a anaconda env with cmake hdf5 and gcc

MAARIFA:build intipedroso$ src/karp 
dyld: Library not loaded: @rpath/libhdf5.10.dylib
  Referenced from: /Users/intipedroso/DATA/app/Karp/build/src/karp
  Reason: image not found
Abort trap: 6

cmake output

~/DATA/app/miniconda2/envs/karp/bin/cmake -DCMAKE_CXX_COMPILER=/Users/intipedroso/DATA/app/miniconda2/envs/karp/bin/c++ -DCMAKE_C_COMPILER=/Users/intipedroso/DATA/app/miniconda2/envs/karp/bin/gcc ..
-- The C compiler identification is GNU 4.8.5
-- The CXX compiler identification is GNU 4.8.5
-- Checking whether C compiler has -isysroot
-- Checking whether C compiler has -isysroot - yes
-- Checking whether C compiler supports OSX deployment target flag
-- Checking whether C compiler supports OSX deployment target flag - yes
-- Check for working C compiler: /Users/intipedroso/DATA/app/miniconda2/envs/karp/bin/gcc
-- Check for working C compiler: /Users/intipedroso/DATA/app/miniconda2/envs/karp/bin/gcc -- works
-- Detecting C compiler ABI info
-- Checking if C linker supports --verbose
-- Checking if C linker supports --verbose - no
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Checking whether CXX compiler has -isysroot
-- Checking whether CXX compiler has -isysroot - yes
-- Checking whether CXX compiler supports OSX deployment target flag
-- Checking whether CXX compiler supports OSX deployment target flag - yes
-- Check for working CXX compiler: /Users/intipedroso/DATA/app/miniconda2/envs/karp/bin/c++
-- Check for working CXX compiler: /Users/intipedroso/DATA/app/miniconda2/envs/karp/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Checking if CXX linker supports --verbose
-- Checking if CXX linker supports --verbose - no
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
shared build
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - found
-- Found Threads: TRUE  
-- HDF5: Using hdf5 compiler wrapper to determine C configuration
-- Found HDF5: /Users/intipedroso/DATA/app/miniconda2/envs/karp/lib/libhdf5.dylib;/usr/lib/libpthread.dylib;/usr/lib/libz.dylib;/usr/lib/libdl.dylib;/usr/lib/libm.dylib (found version "1.8.17")  
-- Found ZLIB: /usr/lib/libz.dylib (found version "1.2.8") 
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/intipedroso/DATA/app/Karp/build

running make throws some errors of the type

/var/folders/rs/klgq82gx2ws8ljvyk70c77fm0000gn/T//ccwk8EjF.s:12012:11: note: change section name to "__text"
        .section __TEXT,__textcoal_nt,coalesced,pure_instructions

and

[ 83%] Building C object src/CMakeFiles/karp_core.dir/ssw.c.o
cc1: warning: command line option ‘-std=c++11’ is valid for C++/ObjC++ but not for C [enabled by default]
[ 88%] Linking CXX static library libkarp_core.a

Any ideas!!!

many thanks in advance

@inti
Copy link
Author

inti commented Mar 22, 2017

I should add

MAARIFA:build intipedroso$ uname -a
Darwin MAARIFA 16.4.0 Darwin Kernel Version 16.4.0: Thu Dec 22 22:53:21 PST 2016; root:xnu-3789.41.3~3/RELEASE_X86_64 x86_64

thanks again

@mreppell
Copy link
Owner

It looks like you need to modify your path so that the program can find the library in your anaconda environment. Looking at others who have had this issue with other software it looks like a possible solution may be adding the fallback library path

export ANACONDA_HOME=$HOME/anaconda
export DYLD_FALLBACK_LIBRARY_PATH=$ANACONDA_HOME/lib:/usr/local/lib:/usr/lib

If that doesn't work, when you are in your environment check if you are able to locate hdf5 using 'ld -lhdf5 --verbose' and see what the output is

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants