Trouble Building Third Party Libraries
-
- Posts: 3
- Joined: Mon Jul 20, 2020 2:55 pm America/New_York
Trouble Building Third Party Libraries
Hello!
I have run into an issue trying to execute BuildIt in the $OCSSWROOT/opt/src directory in order to build the third party libraries.
I am trying to compile seadas 7.5.3 on Linux Ubuntu 16.04
I am running into an issue when the HDF5 directory is reached, where I get the error message:
CMake Error at /usr/share/cmake-3.5/Modules/CMakePackageConfigHelpers.cmake:254 (file):
file RELATIVE_PATH must be passed a full path to the file:
Call Stack (most recent call first):
CMakeInstallation.cmake:85 (configure_package_config_file)
CMakeLists.txt:813 (include)
-- Configuring incomplete, errors occurred!
See also "/home/maxwell/ocssw/opt/src/hdf5/hdf5-1.8.18/build/CMakeFiles/CMakeOutput.log".
See also "/home/maxwell/ocssw/opt/src/hdf5/hdf5-1.8.18/build/CMakeFiles/CMakeError.log".
***** cmake failed *****
***** BuildIt (hdf5) failed *****
A bit earlier in the terminal output, I get this warning:
CMake Warning at CMakeFilters.cmake:36 (find_package):
Could not find a package configuration file provided by "ZLIB" with any of
the following names:
ZLIBConfig.cmake
zlib-config.cmake
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.8")
-- Filter ZLIB is ON
I get the warning but then zlib is found, and I do know that zlib has been installed on this computer. Any help as to why cmake is failing would be greatly appreciated, I have cmake 3.5 and zlib 1.2.8. I have all the necessary toolkits listed in requirements installed, including zlib1g-dev because I am on Ubuntu 16.04.
Thank you!
I have run into an issue trying to execute BuildIt in the $OCSSWROOT/opt/src directory in order to build the third party libraries.
I am trying to compile seadas 7.5.3 on Linux Ubuntu 16.04
I am running into an issue when the HDF5 directory is reached, where I get the error message:
CMake Error at /usr/share/cmake-3.5/Modules/CMakePackageConfigHelpers.cmake:254 (file):
file RELATIVE_PATH must be passed a full path to the file:
Call Stack (most recent call first):
CMakeInstallation.cmake:85 (configure_package_config_file)
CMakeLists.txt:813 (include)
-- Configuring incomplete, errors occurred!
See also "/home/maxwell/ocssw/opt/src/hdf5/hdf5-1.8.18/build/CMakeFiles/CMakeOutput.log".
See also "/home/maxwell/ocssw/opt/src/hdf5/hdf5-1.8.18/build/CMakeFiles/CMakeError.log".
***** cmake failed *****
***** BuildIt (hdf5) failed *****
A bit earlier in the terminal output, I get this warning:
CMake Warning at CMakeFilters.cmake:36 (find_package):
Could not find a package configuration file provided by "ZLIB" with any of
the following names:
ZLIBConfig.cmake
zlib-config.cmake
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.8")
-- Filter ZLIB is ON
I get the warning but then zlib is found, and I do know that zlib has been installed on this computer. Any help as to why cmake is failing would be greatly appreciated, I have cmake 3.5 and zlib 1.2.8. I have all the necessary toolkits listed in requirements installed, including zlib1g-dev because I am on Ubuntu 16.04.
Thank you!
Filters:
Trouble Building Third Party Libraries
This is a duplicate of Could not find a package configuration file provided by "ZLIB"- BuildIt (hdf5) failed
If you are trying to build the OCSSW software from source because there is a problem with NASA's binaries, it might be better to sort out that problem.
Ubuntu 16.04 has cmake-3.5.1. I tried building the hdf5 library in an Ubuntu 16.04 VM and get the same error, but a more recent version, cmake-3.16.4 from cmake.org,
succeeds in building the hdf5 library.
If you are trying to build the OCSSW software from source because there is a problem with NASA's binaries, it might be better to sort out that problem.
Ubuntu 16.04 has cmake-3.5.1. I tried building the hdf5 library in an Ubuntu 16.04 VM and get the same error, but a more recent version, cmake-3.16.4 from cmake.org,
succeeds in building the hdf5 library.
-
- Subject Matter Expert
- Posts: 271
- Joined: Thu Mar 05, 2009 10:25 am America/New_York
- Been thanked: 2 times
Trouble Building Third Party Libraries
I just made a machine with Ubuntu 16.04, installed cmake 3.18.0, git, bison, flex, lib32z1-dev
opt/src would not build unless I deleted
opt/bin
opt/lib
then BuildIt worked fine.
don
opt/src would not build unless I deleted
opt/bin
opt/lib
then BuildIt worked fine.
don
-
- Posts: 3
- Joined: Mon Jul 20, 2020 2:55 pm America/New_York
Trouble Building Third Party Libraries
Thank you both, I have fixed the error I was running into and am now able to build the HDF5 library, however I am coming across another error reading:
checking for szlib... suppressed
checking hdf5.h usability... no
checking hdf5.h presence... no
checking for hdf5.h... no
checking for H5Fcreate in -lhdf5... yes
configure: error: can't link against HDF5 library
***** configure failed *****
***** BuildIt (hdfeos5) failed *****
I have seen errors similar to this one, but usually they read as can't find or link to the hdf5 library, and I am not sure what to do to fix this issue. Any help with this would be appreciated!
I also tried specifying the direct path to the HDF5 library using --with-hdf5= *my path* and the same error presented itself.
checking for szlib... suppressed
checking hdf5.h usability... no
checking hdf5.h presence... no
checking for hdf5.h... no
checking for H5Fcreate in -lhdf5... yes
configure: error: can't link against HDF5 library
***** configure failed *****
***** BuildIt (hdfeos5) failed *****
I have seen errors similar to this one, but usually they read as can't find or link to the hdf5 library, and I am not sure what to do to fix this issue. Any help with this would be appreciated!
I also tried specifying the direct path to the HDF5 library using --with-hdf5= *my path* and the same error presented itself.
Trouble Building Third Party Libraries
Your problem appears to be the test for "H5Fcreate in -lhdf5". "BuildIt" works for two fairly fresh 1604 installs with slightly different cmake version. I just updated my system before running "BuildIT" (with the debug flag set so I can see config.log) in the hdfeos5 directory. I got:
You should have
"
Hope this is helpful.
checking for szlib... suppressed
checking hdf5.h usability... yes
checking hdf5.h presence... no
configure: WARNING: hdf5.h: accepted by the compiler, rejected by the preprocessor!
configure: WARNING: hdf5.h: proceeding with the compiler's result
checking for hdf5.h... yes
checking for H5Fcreate in -lhdf5... yes
checking if HDF5 threadsafe mode is enabled... no
[...]
Everything Built Successfully
You should have
hdfeos5/hdfeos5/config.log
which provides details of the configuration (if you don't, try running "
OCSSW_DEBUG=1 ./BuildIt > BuildIt.log 2>&1
" in the top hdfeos5
directory. The relevant lines for my system have:configure:22364: checking hdf5.h usability
configure:22381: gcc -c -I/home/seadas/ocssw/opt/include -g3 -gdwarf-2 conftest.c >&5
configure:22387: $? = 0
configure:22401: result: yes
configure:22405: checking hdf5.h presence
configure:22420: gcc -E conftest.c
conftest.c:24:18: fatal error: hdf5.h: No such file or directory
compilation terminated.
configure:22426: $? = 1
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "hdf-eos5"
|[...]
| /* end confdefs.h. */
| #include <hdf5.h>
configure:22440: result: no
configure:22446: WARNING: hdf5.h: accepted by the compiler, rejected by the preprocessor!
configure:22448: WARNING: hdf5.h: proceeding with the compiler's result
configure:22473: checking for hdf5.h
configure:22481: result: yes
configure:22497: checking for H5Fcreate in -lhdf5
configure:22532: gcc -o conftest -I/home/seadas/ocssw/opt/include -g3 -gdwarf-2 \\
-L/home/seadas/ocssw/opt/lib \\
-Wl,-rpath=/home/seadas/ocssw/opt/lib,-rpath=\$$ORIGIN/../lib,-rpath=\$$ORIGIN/../opt/lib \\
conftest.c -lhdf5_hl -lhdf5 -lz -lm >&5
configure:22538: $? = 0
configure:22556: result: yes
Hope this is helpful.
-
- Posts: 1519
- Joined: Wed Sep 18, 2019 6:15 pm America/New_York
- Been thanked: 9 times
Trouble Building Third Party Libraries
Make sure that you don't have another HDF5 library installed, well, at least not one accessible from the shell you're running BuildIt in (in your PATH).
We've seen that this can sometimes confuse CMake and configure. it usually works, but isn't portable...but if it is the problem, it might be because of an incompatible version was found (the one we package is compatible :grin:). Also make sure LIB3_DIR points to the $OCSSWROOT/opt/ tree.
Sean
We've seen that this can sometimes confuse CMake and configure. it usually works, but isn't portable...but if it is the problem, it might be because of an incompatible version was found (the one we package is compatible :grin:). Also make sure LIB3_DIR points to the $OCSSWROOT/opt/ tree.
Sean
-
- Posts: 3
- Joined: Mon Jul 20, 2020 2:55 pm America/New_York
Trouble Building Third Party Libraries
Thank you both, I was able to fix the issue and buildit ran successfully, thank you again!