building on CentOS 7

Use this Forum to find information on, or ask a question about, NASA Earth Science data.
Post Reply
mcanto
Posts: 6
Joined: Wed May 02, 2018 10:15 am America/New_York
Answers: 0

building on CentOS 7

by mcanto » Mon Jun 25, 2018 1:44 am America/New_York

Hi,

I am trying to build the processing codes on a CentOS Linux release 7.5.1804. I got as far as running "cmake .." -- this is after jumping several hoops many times along the way. But I got the following error when I executed the "make" command:

[ 21%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/b128_msk_get.c.o
[ 21%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/b128_wd_bit.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/b128_box_num.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/read_mask.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/fresnel.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_generic_write.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_hdf_generic_read.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_nc_generic_read.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_mos_hdf.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_octs_hdf.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_czcs_hdf.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/ll2vec.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1a_seawifs.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1a_osmi.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_ocm_hdf.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_ocm2_hdf.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_ocmdb_hdf.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_hmodis_hdf.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/calibrate_viirs.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1b_viirs_nc.c.o
[ 22%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/l1_viirs_nc.c.o
/export/home/l-p/mcanto/ocssw/ocssw-src/src/l2gen/l1_viirs_nc.c:12:39: fatal error: Calibrate_Viirs_Connector.h: No such file or directory
#include <Calibrate_Viirs_Connector.h>
                                       ^
compilation terminated.
make[2]: *** [src/l2gen/CMakeFiles/l1det2det.dir/l1_viirs_nc.c.o] Error 1
make[1]: *** [src/l2gen/CMakeFiles/l1det2det.dir/all] Error 2
make: *** [all] Error 2

I've read previous threads that has similar errors and got the idea of following what was suggested at https://seadas.gsfc.nasa.gov/build_ocssw/rhel/ to download the prebuilt VIIRS libs, then deleted/recreated the build folder, issued "cmake .." and then "make" again

Now, I get this error:

[ 29%] Building Fortran object src/l2gen/CMakeFiles/l1det2det.dir/dtran_brdf.f.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/turbid.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/glint.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/mumm.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/get_rhown_nir.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/aerosol.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/nlw_outband.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/airmass.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/bin_climatology.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/anc_acq.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/met_cvt.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/ncio.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/swim.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/get_atrem_corl1.c.o
[ 29%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/rdatreminfo.c.o
[ 29%] Building Fortran object src/l2gen/CMakeFiles/l1det2det.dir/atrem_app_refl_plus_gas_removal_l2.f90.o
[ 29%] Building Fortran object src/l2gen/CMakeFiles/l1det2det.dir/atrem_bndprms.f.o
[ 30%] Building Fortran object src/l2gen/CMakeFiles/l1det2det.dir/atrem_tpvmr_init.f.o
[ 30%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/numerical.c.o
[ 30%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/raman.c.o
[ 30%] Building C object src/l2gen/CMakeFiles/l1det2det.dir/get_psd_ksm.c.o
[ 30%] Linking CXX executable l1det2det
/export/home/l-p/mcanto/ocssw/opt/lib/libViirsCal.a(VcstViirsCal.cpp.o): In function `VcstViirsCal::write_img()':
VcstViirsCal.cpp:(.text+0x7720): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
/export/home/l-p/mcanto/ocssw/opt/lib/libViirsCal.a(VcstViirsCal.cpp.o): In function `VcstViirsCal::write_mod()':
VcstViirsCal.cpp:(.text+0xa540): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
/export/home/l-p/mcanto/ocssw/opt/lib/libViirsCal.a(VcstViirsCal.cpp.o): In function `VcstViirsCal::write_cdg()':
VcstViirsCal.cpp:(.text+0xcd48): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
/export/home/l-p/mcanto/ocssw/opt/lib/libViirsCal.a(VcstViirsCal.cpp.o): In function `VcstViirsCal::write_dnb()':
VcstViirsCal.cpp:(.text+0xfe08): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
/export/home/l-p/mcanto/ocssw/opt/lib/libViirsCal.a(VcstObc.cpp.o): In function `VcstObc::write_global_attributes(netCDF::NcFile*)':
VcstObc.cpp:(.text+0x8b6c): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
/export/home/l-p/mcanto/ocssw/opt/lib/libViirsCal.a(VcstObc.cpp.o):VcstObc.cpp:(.text+0xe92d): more undefined references to `std::__throw_out_of_range_fmt(char const*, ...)' follow
collect2: error: ld returned 1 exit status
make[2]: *** [src/l2gen/l1det2det] Error 1
make[1]: *** [src/l2gen/CMakeFiles/l1det2det.dir/all] Error 2
make: *** [all] Error 2

This is probably not a surprise (?) as the VIIRS libraries were prebuilt for CentOS 6. Or maybe there is something else going on here which I have no idea about and would appreciate if you could help out.
Do you have similar prebuilt VIIRS libraries for CentOS 7? I am just naively assuming that this might resolve the error I am getting and would finally be able to compile and complete installation.

Thanks for your help in advance!

Cheers,
Tess

Tags:

OB.DAAC - SeanBailey
User Services
User Services
Posts: 1470
Joined: Wed Sep 18, 2019 6:15 pm America/New_York
Answers: 1
Been thanked: 5 times

building on CentOS 7

by OB.DAAC - SeanBailey » Mon Jun 25, 2018 5:14 pm America/New_York


mcanto
Posts: 6
Joined: Wed May 02, 2018 10:15 am America/New_York
Answers: 0

building on CentOS 7

by mcanto » Tue Jun 26, 2018 9:06 pm America/New_York

Sean,

Thanks for re-pointing me to the instructions on that link. I missed something and now was able to progress further, but still didn't quite make it to the end! :cry:

Here's the log leading to the error:

[100%] Built target scpad_viirs

[100%] Built target l1aextract_viirs

Scanning dependencies of target l1agen_viirs
[100%] Building CXX object src/l1agen_viirs/CMakeFiles/l1agen_viirs.dir/l1agen_viirs.cpp.o
[100%] Building CXX object src/l1agen_viirs/CMakeFiles/l1agen_viirs.dir/l1aFile.cpp.o
[100%] Building CXX object src/l1agen_viirs/CMakeFiles/l1agen_viirs.dir/createNCDF_viirs.cpp.o
[100%] Building C object src/l1agen_viirs/CMakeFiles/l1agen_viirs.dir/Usds.c.o
make[2]: *** No rule to make target `/export/home/l-p/mcanto/ocssw/opt/lib/libViirsRice.a', needed by `src/l1agen_viirs/l1agen_viirs'.  Stop.
make[1]: *** [src/l1agen_viirs/CMakeFiles/l1agen_viirs.dir/all] Error 2
make: *** [all] Error 2
[root@hpc-compute1 build]#


Any suggestion? Thanks.

Tess

OB.DAAC - SeanBailey
User Services
User Services
Posts: 1470
Joined: Wed Sep 18, 2019 6:15 pm America/New_York
Answers: 1
Been thanked: 5 times

building on CentOS 7

by OB.DAAC - SeanBailey » Thu Jun 28, 2018 1:43 pm America/New_York

Did you grab the latest version of the viirs tarball (they were posted June 25th at 13:58 EDT).
If not, give that a try.  If so, then the simple solution is to disable the VIIRS build (cmake -DBUILD_VIIRS_L1=0).
A more involved solution will have to wait...Don worked on these but is out of the office this week. 

Sean

OB SeaDAS - dshea
Subject Matter Expert
Subject Matter Expert
Posts: 259
Joined: Thu Mar 05, 2009 10:25 am America/New_York
Answers: 0
Been thanked: 2 times

building on CentOS 7

by OB SeaDAS - dshea » Thu Jun 28, 2018 2:16 pm America/New_York

viirs.centos7.gcc5.tar.gz from step 9 for CentOS 7 has that library.  I guess I would make sure /export/home/l-p/mcanto/ocssw/opt/lib/libViirsRice.a exists and delete your $OCSSWROOT/ocssw-src/build directory and run cmake again in a new build directory.

don

Post Reply