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

make check fails for netCDF-C 4.9.2 (Docker) build #2919

Open
sr-murthy opened this issue May 5, 2024 · 7 comments
Open

make check fails for netCDF-C 4.9.2 (Docker) build #2919

sr-murthy opened this issue May 5, 2024 · 7 comments
Assignees
Milestone

Comments

@sr-murthy
Copy link

sr-murthy commented May 5, 2024

I'm trying to build a Docker image (Ubuntu 18.04) with netCDF-C 4.9.2 from source - I'm following the installation guide for building it with HDF4 support. In the Dockerfile here are the chained instructions for the netCDF build:

...
# Build netCDF C lib.
ARG NETCDF_C_VER=4.9.2
RUN wget https://github.com/Unidata/netcdf-c/archive/refs/tags/v${NETCDF_C_VER}.tar.gz && \
    tar zxvf v${NETCDF_C_VER}.tar.gz && \
    cd netcdf-c-${NETCDF_C_VER} && \
    CPPFLAGS="-Ihdf5-${HDF5_VER}/include -Ihdf-${HDF4_VER}-2/include" \
    LDFLAGS="-Lhdf5-${HDF5_VER}/lib -Lhdf-${HDF4_VER}-2/lib" && \
    ./configure --prefix=/usr/local --disable-byterange --enable-shared --enable-hdf4 --enable-hdf4-file-tests && \
    make && make check && make install && \
    cd .. && rm -rf netcdf-c-${NETCDF_C_VER} && rm -f v${NETCDF_C_VER}.tar.gz
...

The error occurs during make check:

113.0 Making check in include
113.0 make[1]: Entering directory '/netcdf-c-4.9.2/include'
113.0 make[1]: Nothing to be done for 'check'.
113.0 make[1]: Leaving directory '/netcdf-c-4.9.2/include'
113.0 Making check in libdispatch
113.0 make[1]: Entering directory '/netcdf-c-4.9.2/libdispatch'
113.0 make[1]: Nothing to be done for 'check'.
113.0 make[1]: Leaving directory '/netcdf-c-4.9.2/libdispatch'
113.0 Making check in libsrc
113.0 make[1]: Entering directory '/netcdf-c-4.9.2/libsrc'
113.0 make[1]: Nothing to be done for 'check'.
113.0 make[1]: Leaving directory '/netcdf-c-4.9.2/libsrc'
113.0 Making check in libsrc4
113.1 make[1]: Entering directory '/netcdf-c-4.9.2/libsrc4'
113.1 make[1]: Nothing to be done for 'check'.
113.1 make[1]: Leaving directory '/netcdf-c-4.9.2/libsrc4'
113.1 Making check in libhdf4
113.1 make[1]: Entering directory '/netcdf-c-4.9.2/libhdf4'
113.1 make[1]: Nothing to be done for 'check'.
113.1 make[1]: Leaving directory '/netcdf-c-4.9.2/libhdf4'
113.1 Making check in libhdf5
113.1 make[1]: Entering directory '/netcdf-c-4.9.2/libhdf5'
113.1 make[1]: Nothing to be done for 'check'.
113.1 make[1]: Leaving directory '/netcdf-c-4.9.2/libhdf5'
113.1 Making check in libncpoco
113.1 make[1]: Entering directory '/netcdf-c-4.9.2/libncpoco'
113.1 make[1]: Nothing to be done for 'check'.
113.1 make[1]: Leaving directory '/netcdf-c-4.9.2/libncpoco'
113.1 Making check in libnczarr
113.2 make[1]: Entering directory '/netcdf-c-4.9.2/libnczarr'
113.2 make[1]: Nothing to be done for 'check'.
113.2 make[1]: Leaving directory '/netcdf-c-4.9.2/libnczarr'
113.2 Making check in liblib
113.2 make[1]: Entering directory '/netcdf-c-4.9.2/liblib'
113.2 make[1]: Nothing to be done for 'check'.
113.2 make[1]: Leaving directory '/netcdf-c-4.9.2/liblib'
113.2 Making check in ncgen3
113.2 make[1]: Entering directory '/netcdf-c-4.9.2/ncgen3'
113.2 make  check-TESTS
113.2 make[2]: Entering directory '/netcdf-c-4.9.2/ncgen3'
113.2 make[3]: Entering directory '/netcdf-c-4.9.2/ncgen3'
113.3 PASS: run_tests.sh
113.3 FAIL: run_nc4_tests.sh
113.4 ============================================================================
113.4 Testsuite summary for netCDF 4.9.2
113.4 ============================================================================
113.4 # TOTAL: 2
113.4 # PASS:  1
113.4 # SKIP:  0
113.4 # XFAIL: 0
113.4 # FAIL:  1
113.4 # XPASS: 0
113.4 # ERROR: 0
113.4 ============================================================================
113.4 See ncgen3/test-suite.log
113.4 Please report to support-netcdf@unidata.ucar.edu
113.4 ============================================================================
113.4 Makefile:938: recipe for target 'test-suite.log' failed
113.4 make[3]: *** [test-suite.log] Error 1
113.4 make[2]: *** [check-TESTS] Error 2
113.4 make[3]: Leaving directory '/netcdf-c-4.9.2/ncgen3'
113.4 Makefile:1044: recipe for target 'check-TESTS' failed
113.4 make[2]: Leaving directory '/netcdf-c-4.9.2/ncgen3'
113.4 Makefile:1126: recipe for target 'check-am' failed
113.4 make[1]: Leaving directory '/netcdf-c-4.9.2/ncgen3'
113.4 make[1]: *** [check-am] Error 2
113.4 make: *** [check-recursive] Error 1
113.4 Makefile:769: recipe for target 'check-recursive' failed

Earlier instructions build HDF4 (4.2.16) and HDF5 (1.14.4-2) from source, successfully. Here are the chained instructions for those:

#Build HDF4 lib.
ARG HDF4_VER=4.2.16
RUN wget https://hdf-wordpress-1.s3.amazonaws.com/wp-content/uploads/manual/HDF4/HDF${HDF4_VER}-2/src/hdf-${HDF4_VER}-2.tar.gz && \
    tar zxvf hdf-${HDF4_VER}-2.tar.gz && \
    cd hdf-${HDF4_VER}-2 && \
    ./configure --prefix=/usr/local/ --enable-shared --disable-netcdf --disable-fortran && \
    make && make check && make install && \
    cd .. && \
    rm -f hdf-${HDF4_VER}-2.tar.gz
...
# Build HDF5 lib.
ARG HDF5_VER=1.14.4-2
ARG HDF5_DOTVER=1.14.4.2
RUN wget https://github.com/HDFGroup/hdf5/releases/download/hdf5_${HDF5_DOTVER}/hdf5-${HDF5_VER}.tar.gz && \
    tar zxvf hdf5-${HDF5_VER}.tar.gz && \
    cd hdf5-${HDF5_VER} && \
    ./configure --prefix=/usr/local/ && \
    make && make check && make install && \
    cd .. && \
    rm -f hdf5-${HDF5_VER}.tar.gz

My guess is there is some inconsistency in the way in which configure and make have been run for HDF4 vs netCDF, but I'm not sure.

P. S. Of course 18.04 is deprecated, but I need to build one for it.

@WardF
Copy link
Member

WardF commented May 15, 2024

Do you happen to have the config.log and test-suite.log files generated? That would shed a lot of light on what's happening under the hood.

@sr-murthy
Copy link
Author

Those would be inside the Docker container, but I could extract that and get back to you.

@sr-murthy
Copy link
Author

sr-murthy commented May 15, 2024

@WardF Here are the files extracted from the (Ubuntu 18.04) container - I just ran the build steps inside the container and reproduced the error.

test-suite.log
config.log

P. S. The Dockerfile I'm using is here. Along with HDF4 and HDF5, I'm also trying to build HDF-EOS2 and H4CF from source. So the (attempted) build order inside the container is:

  1. HDF4
  2. HDF-EOS2
  3. HDF5
  4. netCDF-C
  5. H4CF

Steps 1-3 succeed - it's step #4 (netCDF-C) that fails.

@sr-murthy sr-murthy changed the title make check fails for netCDF 4.9.2 (Docker) build make check fails for netCDF-C 4.9.2 (Docker) build May 15, 2024
@WardF
Copy link
Member

WardF commented Jun 3, 2024

Thanks, I'll take a look at this. Do you happen to have the apt.txt file referenced by the Dockerfile you linked to? Also, is there any chance you have the test-suite.log file for the failing tests? The one you shared shows no errors.

@WardF WardF self-assigned this Jun 3, 2024
@WardF WardF added this to the 4.9.3 milestone Jun 3, 2024
@sr-murthy
Copy link
Author

sr-murthy commented Jun 4, 2024

@WardF The apt file is here..

Yes I can see the test-suite.log didn't contain any errors, which is why I raised the issue - the chained build step clearly failed on make check. Would there be a separate log file make check, and where would I look for it?

@sr-murthy
Copy link
Author

I will try it again, and see if I can find anything else that can pinpoint the make check errors.

@sr-murthy
Copy link
Author

@WardF I believe I am running configure correctly, but do you see any issues with that?

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