cancel
Showing results for 
Search instead for 
Did you mean: 

PC Drivers & Software

RobertoG
Journeyman III

Problems compiling HDF5 with AOCC

Good evening. I've been trying to compile HDF5 library in its latest version, but I keep getting to a problem.

./configure works perfectly, but whenever I do make, HDF5 throws an error saying as follows:

*./H5_buildiface: error while loading shared libraries: libomp.so: cannot open shared object file: No such file or directory
make[3]: *** [Makefile:1513: H5_gen.F90] Error 127*

 

In short, it says that it can't finde libomp.so. However, the path for libomp.so contained within AOCC is perfectly defined. These are my bashrc lines:
#AOCC
export LIBRARY_PATH=/usr/lib64:/usr/lib/x86_64-linux-gnu:/usr/lib:/usr/lib32:$LIBRARY_PATH
export LD_LIBRARY_PATH=/usr/lib64:/usr/lib/x86_64-linux-gnu:/usr/lib:/usr/lib32:$LD_LIBRARY_PATH
export DIRAOCC=/home/roberto/AMD
export DIR=/home/roberto/WRF_AOCC/LIBRARIES
export CC=$DIRAOCC/AOCC/bin/clang
export CXX=$DIRAOCC/AOCC/bin/clang++
export FC=$DIRAOCC/AOCC/bin/flang
export F77=$FC
export comflag="-O2 -march=znver2 -mtune=znver2"
export PATH=/home/roberto/AMD/AOCC/bin:$PATH
export PATH=/home/roberto/AMD/AOCC/share/opt-viewer:$PATH
export LIBRARY_PATH=$DIRAOCC/AOCC/lib:$LIBRARY_PATH
export LD_LIBRARY_PATH=$DIRAOCC/AOCC/lib:$DIRAOCC/AOCC/ompd
export C_INCLUDE_PATH=$C_INCLUDE_PATH:$DIRAOCC/AOCC/include
export CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:$DIRAOCC/AOCC/include
export LDFLAGS="-L$DIRAOCC/AOCC/lib -L$DIR/grib2/lib"
export CPPFLAGS="-L$DIRAOCC/AOCC/include -I$DIR/grib2/include"

 

I do even pass all the paths and specify compilers in ./configure command line, so that I make sure that the program gets it correct.


Any ideas on how to solve it or what is happening?

AOCC version: 3.2
OS: Kubuntu 21.10
CPU: R9 3900X

Thank you!

0 Likes
1 Reply
nyp
Journeyman III

I have the same question, why target can't find library even though it is written in file. Also strange, that it is not marked as "Needed" 

readelf -d tx_f90_logical

Dynamic section at offset 0xed0 contains 33 entries:
Tag Type Name/Value
0x000000000000001d (RUNPATH) Library runpath: [/opt/AMD/aocc-compiler-4.0.0/lib:/opt/AMD/aocc-compiler-4.0.0/bin/../lib]
0x0000000000000001 (NEEDED) Shared library: [libflang.so]
0x0000000000000001 (NEEDED) Shared library: [libflangrti.so]
0x0000000000000001 (NEEDED) Shared library: [libpgmath.so]
0x0000000000000001 (NEEDED) Shared library: [libquadmath.so.0]
0x0000000000000001 (NEEDED) Shared library: [libompstub.so]
0x0000000000000001 (NEEDED) Shared library: [libm.so.6]
0x0000000000000001 (NEEDED) Shared library: [librt.so.1]
0x0000000000000001 (NEEDED) Shared library: [libpthread.so.0]
0x0000000000000001 (NEEDED) Shared library: [libc.so.6]

0 Likes