mirror of
https://github.com/Unidata/netcdf-c.git
synced 2025-03-19 17:30:27 +08:00
Replace ENABLE_NCZARR with NETCDF_ENABLE_NCZARR
This commit is contained in:
parent
7f8ad2c250
commit
d1334f7b88
18
.github/workflows/run_tests_osx.yml
vendored
18
.github/workflows/run_tests_osx.yml
vendored
@ -83,9 +83,9 @@ jobs:
|
||||
if: matrix.use_dap == 'dap_off'
|
||||
- run: echo "NETCDF_ENABLE_DAP=--enable-dap" >> $GITHUB_ENV
|
||||
if: matrix.use_dap == 'dap_on'
|
||||
- run: echo "ENABLE_NCZARR=--disable-nczarr" >> $GITHUB_ENV
|
||||
- run: echo "NETCDF_ENABLE_NCZARR=--disable-nczarr" >> $GITHUB_ENV
|
||||
if: matrix.use_nczarr == 'nczarr_off'
|
||||
- run: echo "ENABLE_NCZARR=--enable-nczarr" >> $GITHUB_ENV
|
||||
- run: echo "NETCDF_ENABLE_NCZARR=--enable-nczarr" >> $GITHUB_ENV
|
||||
if: matrix.use_nczarr == 'nczarr_on'
|
||||
|
||||
###
|
||||
@ -116,7 +116,7 @@ jobs:
|
||||
|
||||
- name: Configure
|
||||
shell: bash -l {0}
|
||||
run: CFLAGS=${CFLAGS} LDFLAGS=${LDFLAGS} LD_LIBRARY_PATH=${LD_LIBRARY_PATH} ./configure ${NETCDF_ENABLE_HDF5} ${NETCDF_ENABLE_DAP} ${ENABLE_NCZARR}
|
||||
run: CFLAGS=${CFLAGS} LDFLAGS=${LDFLAGS} LD_LIBRARY_PATH=${LD_LIBRARY_PATH} ./configure ${NETCDF_ENABLE_HDF5} ${NETCDF_ENABLE_DAP} ${NETCDF_ENABLE_NCZARR}
|
||||
if: ${{ success() }}
|
||||
|
||||
- name: Look at config.log if error
|
||||
@ -145,7 +145,7 @@ jobs:
|
||||
|
||||
# - name: Make Distcheck
|
||||
# shell: bash -l {0}
|
||||
# run: CFLAGS=${CFLAGS} LDFLAGS=${LDFLAGS} LD_LIBRARY_PATH=${LD_LIBRARY_PATH} DISTCHECK_CONFIGURE_FLAGS="${NETCDF_ENABLE_HDF4} ${NETCDF_ENABLE_HDF5} ${NETCDF_ENABLE_DAP} ${ENABLE_NCZARR}" make distcheck
|
||||
# run: CFLAGS=${CFLAGS} LDFLAGS=${LDFLAGS} LD_LIBRARY_PATH=${LD_LIBRARY_PATH} DISTCHECK_CONFIGURE_FLAGS="${NETCDF_ENABLE_HDF4} ${NETCDF_ENABLE_HDF5} ${NETCDF_ENABLE_DAP} ${NETCDF_ENABLE_NCZARR}" make distcheck
|
||||
# if: ${{ success() }}
|
||||
|
||||
#- name: Start SSH Debug
|
||||
@ -188,9 +188,9 @@ jobs:
|
||||
if: matrix.use_dap == 'dap_off'
|
||||
- run: echo "NETCDF_ENABLE_DAP=ON" >> $GITHUB_ENV
|
||||
if: matrix.use_dap == 'dap_on'
|
||||
- run: echo "ENABLE_NCZARR=OFF" >> $GITHUB_ENV
|
||||
- run: echo "NETCDF_ENABLE_NCZARR=OFF" >> $GITHUB_ENV
|
||||
if: matrix.use_nczarr == 'nczarr_off'
|
||||
- run: echo "ENABLE_NCZARR=ON" >> $GITHUB_ENV
|
||||
- run: echo "NETCDF_ENABLE_NCZARR=ON" >> $GITHUB_ENV
|
||||
if: matrix.use_nczarr == 'nczarr_on'
|
||||
- run: echo "CTEST_OUTPUT_ON_FAILURE=1" >> $GITHUB_ENV
|
||||
|
||||
@ -218,7 +218,7 @@ jobs:
|
||||
run: |
|
||||
mkdir build
|
||||
cd build
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=${NETCDF_ENABLE_DAP} -DNETCDF_ENABLE_HDF5=${NETCDF_ENABLE_HDF5} -DENABLE_NCZARR=${ENABLE_NCZARR}
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=${NETCDF_ENABLE_DAP} -DNETCDF_ENABLE_HDF5=${NETCDF_ENABLE_HDF5} -DNETCDF_ENABLE_NCZARR=${NETCDF_ENABLE_NCZARR}
|
||||
|
||||
- name: Print Summary
|
||||
shell: bash -l {0}
|
||||
@ -375,7 +375,7 @@ jobs:
|
||||
run: |
|
||||
mkdir build
|
||||
cd build
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DENABLE_NCZARR=TRUE -D NETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DNETCDF_ENABLE_LIBXML2=FALSE
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DNETCDF_ENABLE_NCZARR=TRUE -D NETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DNETCDF_ENABLE_LIBXML2=FALSE
|
||||
|
||||
- name: Print Summary
|
||||
shell: bash -l {0}
|
||||
@ -450,7 +450,7 @@ jobs:
|
||||
run: |
|
||||
mkdir build
|
||||
cd build
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DENABLE_NCZARR=TRUE -D NETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DNETCDF_ENABLE_LIBXML2=FALSE -DBUILD_SHARED_LIBS=OFF -DCMAKE_C_FLAGS=${CMAKE_C_FLAGS}
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DNETCDF_ENABLE_NCZARR=TRUE -D NETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DNETCDF_ENABLE_LIBXML2=FALSE -DBUILD_SHARED_LIBS=OFF -DCMAKE_C_FLAGS=${CMAKE_C_FLAGS}
|
||||
|
||||
- name: Print Summary
|
||||
shell: bash -l {0}
|
||||
|
18
.github/workflows/run_tests_ubuntu.yml
vendored
18
.github/workflows/run_tests_ubuntu.yml
vendored
@ -440,7 +440,7 @@ jobs:
|
||||
run: |
|
||||
mkdir build
|
||||
cd build
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DENABLE_NCZARR=TRUE -DNETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DNETCDF_ENABLE_LIBXML2=FALSE
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DNETCDF_ENABLE_NCZARR=TRUE -DNETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DNETCDF_ENABLE_LIBXML2=FALSE
|
||||
|
||||
- name: Print Summary
|
||||
shell: bash -l {0}
|
||||
@ -521,7 +521,7 @@ jobs:
|
||||
run: |
|
||||
mkdir build
|
||||
cd build
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DENABLE_NCZARR=TRUE -DNETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DNETCDF_ENABLE_LIBXML2=FALSE -DBUILD_SHARED_LIBS=FALSE -DCMAKE_C_FLAGS=${CMAKE_C_FLAGS}
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DNETCDF_ENABLE_NCZARR=TRUE -DNETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DNETCDF_ENABLE_LIBXML2=FALSE -DBUILD_SHARED_LIBS=FALSE -DCMAKE_C_FLAGS=${CMAKE_C_FLAGS}
|
||||
|
||||
- name: Print Summary
|
||||
shell: bash -l {0}
|
||||
@ -602,7 +602,7 @@ jobs:
|
||||
run: |
|
||||
mkdir build
|
||||
cd build
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_C_COMPILER=mpicc -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DENABLE_NCZARR=TRUE -D NETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DENABLE_PNETCDF=TRUE
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_C_COMPILER=mpicc -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=TRUE -DNETCDF_ENABLE_HDF5=TRUE -DNETCDF_ENABLE_NCZARR=TRUE -D NETCDF_ENABLE_DAP_LONG_TESTS=TRUE -DENABLE_PNETCDF=TRUE
|
||||
|
||||
- name: Print Summary
|
||||
shell: bash -l {0}
|
||||
@ -688,9 +688,9 @@ jobs:
|
||||
if: matrix.use_dap == 'dap_off'
|
||||
- run: echo "NETCDF_ENABLE_DAP=--enable-dap" >> $GITHUB_ENV
|
||||
if: matrix.use_dap == 'dap_on'
|
||||
- run: echo "ENABLE_NCZARR=--disable-nczarr" >> $GITHUB_ENV
|
||||
- run: echo "NETCDF_ENABLE_NCZARR=--disable-nczarr" >> $GITHUB_ENV
|
||||
if: matrix.use_nczarr == 'nczarr_off'
|
||||
- run: echo "ENABLE_NCZARR=--enable-nczarr" >> $GITHUB_ENV
|
||||
- run: echo "NETCDF_ENABLE_NCZARR=--enable-nczarr" >> $GITHUB_ENV
|
||||
if: matrix.use_nczarr == 'nczarr_on'
|
||||
|
||||
###
|
||||
@ -738,7 +738,7 @@ jobs:
|
||||
done
|
||||
current_directory="$(pwd)"
|
||||
mkdir ../build
|
||||
cd ../build && CFLAGS=${CFLAGS} LDFLAGS=${LDFLAGS} LD_LIBRARY_PATH=${LD_LIBRARY_PATH} "${current_directory}/configure" ${NETCDF_ENABLE_HDF5} ${NETCDF_ENABLE_DAP} ${ENABLE_NCZARR}
|
||||
cd ../build && CFLAGS=${CFLAGS} LDFLAGS=${LDFLAGS} LD_LIBRARY_PATH=${LD_LIBRARY_PATH} "${current_directory}/configure" ${NETCDF_ENABLE_HDF5} ${NETCDF_ENABLE_DAP} ${NETCDF_ENABLE_NCZARR}
|
||||
if: ${{ success() }}
|
||||
|
||||
- name: Look at config.log if error
|
||||
@ -830,9 +830,9 @@ jobs:
|
||||
if: matrix.use_dap == 'dap_off'
|
||||
- run: echo "NETCDF_ENABLE_DAP=ON" >> $GITHUB_ENV
|
||||
if: matrix.use_dap == 'dap_on'
|
||||
- run: echo "ENABLE_NCZARR=OFF" >> $GITHUB_ENV
|
||||
- run: echo "NETCDF_ENABLE_NCZARR=OFF" >> $GITHUB_ENV
|
||||
if: matrix.use_nczarr == 'nczarr_off'
|
||||
- run: echo "ENABLE_NCZARR=ON" >> $GITHUB_ENV
|
||||
- run: echo "NETCDF_ENABLE_NCZARR=ON" >> $GITHUB_ENV
|
||||
if: matrix.use_nczarr == 'nczarr_on'
|
||||
- run: echo "CTEST_OUTPUT_ON_FAILURE=1" >> $GITHUB_ENV
|
||||
|
||||
@ -860,7 +860,7 @@ jobs:
|
||||
run: |
|
||||
mkdir build
|
||||
cd build
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=${NETCDF_ENABLE_DAP} -DNETCDF_ENABLE_HDF5=${NETCDF_ENABLE_HDF5} -DENABLE_NCZARR=${ENABLE_NCZARR}
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH} cmake .. -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DNETCDF_ENABLE_DAP=${NETCDF_ENABLE_DAP} -DNETCDF_ENABLE_HDF5=${NETCDF_ENABLE_HDF5} -DNETCDF_ENABLE_NCZARR=${NETCDF_ENABLE_NCZARR}
|
||||
|
||||
- name: Print Summary
|
||||
shell: bash -l {0}
|
||||
|
@ -442,14 +442,14 @@ if(NOT NETCDF_ENABLE_HDF5 OR NOT ENABLE_NETCDF4 OR NOT ENABLE_NETCDF_4)
|
||||
endif()
|
||||
option(NETCDF_ENABLE_HDF4 "Build netCDF-4 with HDF4 read capability(HDF4, HDF5 and Zlib required)." OFF)
|
||||
option(NETCDF_ENABLE_DAP "Enable DAP2 and DAP4 Client." ON)
|
||||
option(ENABLE_NCZARR "Enable NCZarr Client." ON)
|
||||
option(NETCDF_ENABLE_NCZARR "Enable NCZarr Client." ON)
|
||||
option(ENABLE_PNETCDF "Build with parallel I/O for CDF-1, 2, and 5 files using PnetCDF." OFF)
|
||||
set(NETCDF_ENABLE_CDF5 AUTO CACHE STRING "AUTO")
|
||||
option(NETCDF_ENABLE_CDF5 "Enable CDF5 support" ON)
|
||||
|
||||
# Netcdf-4 support (i.e. libsrc4) is required by more than just HDF5 (e.g. NCZarr)
|
||||
# So depending on what above formats are enabled, enable netcdf-4
|
||||
if(NETCDF_ENABLE_HDF5 OR NETCDF_ENABLE_HDF4 OR ENABLE_NCZARR)
|
||||
if(NETCDF_ENABLE_HDF5 OR NETCDF_ENABLE_HDF4 OR NETCDF_ENABLE_NCZARR)
|
||||
set(ENABLE_NETCDF_4 ON CACHE BOOL "Enable netCDF-4 API" FORCE)
|
||||
set(ENABLE_NETCDF4 ON CACHE BOOL "Enable netCDF4 Alias" FORCE)
|
||||
endif()
|
||||
@ -558,7 +558,7 @@ set(REMOTETESTSERVERS "remotetest.unidata.ucar.edu" CACHE STRING "test servers t
|
||||
set(REMOTETESTSERVERS "remotetest.unidata.ucar.edu" CACHE STRING "test servers to use for remote test")
|
||||
|
||||
# Locate some compressors
|
||||
option(NETCDF_ENABLE_FILTER_SZIP "Enable use of Szip compression library if it is available. Required if ENABLE_NCZARR is true." ON)
|
||||
option(NETCDF_ENABLE_FILTER_SZIP "Enable use of Szip compression library if it is available. Required if NETCDF_ENABLE_NCZARR is true." ON)
|
||||
option(NETCDF_ENABLE_FILTER_BZ2 "Enable use of Bz2 compression library if it is available." ON)
|
||||
option(NETCDF_ENABLE_FILTER_BLOSC "Enable use of blosc compression library if it is available." ON)
|
||||
option(NETCDF_ENABLE_FILTER_ZSTD "Enable use of Zstd compression library if it is available." ON)
|
||||
@ -626,7 +626,7 @@ else() # No option specified
|
||||
endif()
|
||||
|
||||
# Try to enable NCZarr zip support
|
||||
option(ENABLE_NCZARR_ZIP "Enable NCZarr ZIP support." OFF)
|
||||
option(NETCDF_ENABLE_NCZARR_ZIP "Enable NCZarr ZIP support." OFF)
|
||||
|
||||
include(CMakeDependentOption)
|
||||
|
||||
@ -684,12 +684,12 @@ endif()
|
||||
# Options for S3 Support
|
||||
option(ENABLE_S3 "Enable S3 support." OFF)
|
||||
option(ENABLE_S3_INTERNAL "Enable S3 Internal support." OFF)
|
||||
option(ENABLE_NCZARR_S3 "Enable NCZarr S3 support; Deprecated in favor of ENABLE_S3" OFF)
|
||||
option(NETCDF_ENABLE_NCZARR_S3 "Enable NCZarr S3 support; Deprecated in favor of ENABLE_S3" OFF)
|
||||
|
||||
if(NOT ENABLE_REMOTE_FUNCTIONALITY)
|
||||
set(ENABLE_S3 OFF CACHE BOOL "" FORCE)
|
||||
set(ENABLE_S3_INTERNAL OFF CACHE BOOL "" FORCE)
|
||||
set(ENABLE_NCZARR_S3 OFF CACHE BOOL "" FORCE)
|
||||
set(NETCDF_ENABLE_NCZARR_S3 OFF CACHE BOOL "" FORCE)
|
||||
endif()
|
||||
|
||||
# Control S3 Testing: Multi-valued option
|
||||
@ -703,17 +703,17 @@ if(WITH_S3_TESTING)
|
||||
message(WARNING "**** DO NOT USE WITH_S3_TESTING=ON UNLESS YOU HAVE ACCESS TO THE UNIDATA S3 BUCKET! ***")
|
||||
endif()
|
||||
|
||||
# ENABLE_NCZARR_S3 is now an alias for ENABLE_S3 (but...)
|
||||
if (NOT ENABLE_S3 AND ENABLE_NCZARR_S3)
|
||||
# NETCDF_ENABLE_NCZARR_S3 is now an alias for ENABLE_S3 (but...)
|
||||
if (NOT ENABLE_S3 AND NETCDF_ENABLE_NCZARR_S3)
|
||||
set(ENABLE_S3 ON CACHE BOOL "NCARR S3" FORCE) # For back compatibility
|
||||
endif()
|
||||
unset(ENABLE_NCZARR_S3)
|
||||
unset(NETCDF_ENABLE_NCZARR_S3)
|
||||
|
||||
if(NOT ENABLE_REMOTE_FUNCTIONALITY)
|
||||
message(WARNING "ENABLE_REMOTE_FUNCTIONALITY=NO => disable all s3 functionality")
|
||||
set(ENABLE_S3 OFF CACHE BOOL "" FORCE)
|
||||
set(ENABLE_S3_INTERNAL OFF CACHE BOOL "" FORCE)
|
||||
set(ENABLE_NCZARR_S3 OFF CACHE BOOL "" FORCE)
|
||||
set(NETCDF_ENABLE_NCZARR_S3 OFF CACHE BOOL "" FORCE)
|
||||
set(NETCDF_ENABLE_HDF5_ROS3 OFF CACHE BOOL "Use ROS3" FORCE)
|
||||
set(WITH_S3_TESTING OFF CACHE STRING "" FORCE)
|
||||
endif()
|
||||
@ -967,7 +967,7 @@ endif()
|
||||
option(NETCDF_ENABLE_FILTER_TESTING "Enable filter testing. Ignored if shared libraries or netCDF4 are not enabled" ${ENABLE_PLUGINS})
|
||||
|
||||
if(NETCDF_ENABLE_FILTER_TESTING)
|
||||
if(NOT NETCDF_ENABLE_HDF5 AND NOT ENABLE_NCZARR)
|
||||
if(NOT NETCDF_ENABLE_HDF5 AND NOT NETCDF_ENABLE_NCZARR)
|
||||
message(WARNING "NETCDF_ENABLE_FILTER_TESTING requires HDF5 and/or NCZarr. Disabling.")
|
||||
set(NETCDF_ENABLE_FILTER_TESTING OFF CACHE BOOL "Enable Filter Testing" FORCE)
|
||||
endif()
|
||||
@ -978,22 +978,22 @@ if(NOT BUILD_SHARED_LIBS)
|
||||
set(NETCDF_ENABLE_FILTER_TESTING OFF)
|
||||
endif()
|
||||
|
||||
option(ENABLE_NCZARR_FILTERS "Enable NCZarr filters" ${ENABLE_PLUGINS})
|
||||
option(ENABLE_NCZARR_FILTERS_TESTING "Enable NCZarr filter testing." ${ENABLE_NCZARR_FILTERS})
|
||||
option(NETCDF_ENABLE_NCZARR_FILTERS "Enable NCZarr filters" ${ENABLE_PLUGINS})
|
||||
option(NETCDF_ENABLE_NCZARR_FILTERS_TESTING "Enable NCZarr filter testing." ${NETCDF_ENABLE_NCZARR_FILTERS})
|
||||
|
||||
# Constraints
|
||||
if (NOT ENABLE_PLUGINS AND ENABLE_NCZARR_FILTERS)
|
||||
message(WARNING "ENABLE_NCZARR_FILTERS requires ENABLE_PLUGINS. Disabling.")
|
||||
set(ENABLE_NCZARR_FILTERS OFF CACHE BOOL "Enable NCZarr Filters." FORCE)
|
||||
if (NOT ENABLE_PLUGINS AND NETCDF_ENABLE_NCZARR_FILTERS)
|
||||
message(WARNING "NETCDF_ENABLE_NCZARR_FILTERS requires ENABLE_PLUGINS. Disabling.")
|
||||
set(NETCDF_ENABLE_NCZARR_FILTERS OFF CACHE BOOL "Enable NCZarr Filters." FORCE)
|
||||
endif()
|
||||
|
||||
IF (NOT ENABLE_NCZARR)
|
||||
message(WARNING "ENABLE_NCZARR==NO => ENABLE_NCZARR_FILTERS==NO AND ENABLE_NCZARR_FILTER_TESTING==NO")
|
||||
set(ENABLE_NCZARR_FILTERS OFF CACHE BOOL "Disable NCZARR_FILTERS" FORCE)
|
||||
IF (NOT NETCDF_ENABLE_NCZARR)
|
||||
message(WARNING "NETCDF_ENABLE_NCZARR==NO => NETCDF_ENABLE_NCZARR_FILTERS==NO AND NETCDF_ENABLE_NCZARR_FILTER_TESTING==NO")
|
||||
set(NETCDF_ENABLE_NCZARR_FILTERS OFF CACHE BOOL "Disable NCZARR_FILTERS" FORCE)
|
||||
endif()
|
||||
|
||||
IF (NOT ENABLE_NCZARR_FILTERS)
|
||||
set(ENABLE_NCZARR_FILTER_TESTING OFF CACHE BOOL "Enable NCZarr Filter Testing" FORCE)
|
||||
IF (NOT NETCDF_ENABLE_NCZARR_FILTERS)
|
||||
set(NETCDF_ENABLE_NCZARR_FILTER_TESTING OFF CACHE BOOL "Enable NCZarr Filter Testing" FORCE)
|
||||
endif()
|
||||
|
||||
set(ENABLE_CLIENTSIDE_FILTERS OFF)
|
||||
@ -1408,7 +1408,7 @@ if(ENABLE_PLUGINS)
|
||||
add_subdirectory(libncpoco)
|
||||
endif()
|
||||
|
||||
if(ENABLE_NCZARR)
|
||||
if(NETCDF_ENABLE_NCZARR)
|
||||
add_subdirectory(libnczarr)
|
||||
file(COPY ${netCDF_SOURCE_DIR}/unit_test/timer_utils.h
|
||||
DESTINATION ${netCDF_BINARY_DIR}/nczarr_test/)
|
||||
@ -1466,7 +1466,7 @@ if(ENABLE_TESTS)
|
||||
if(ENABLE_UNIT_TESTS)
|
||||
add_subdirectory(unit_test)
|
||||
endif(ENABLE_UNIT_TESTS)
|
||||
if(ENABLE_NCZARR)
|
||||
if(NETCDF_ENABLE_NCZARR)
|
||||
add_subdirectory(nczarr_test)
|
||||
endif()
|
||||
endif()
|
||||
@ -1643,9 +1643,9 @@ is_enabled(ENABLE_S3 HAS_S3)
|
||||
is_enabled(ENABLE_S3_AWS HAS_S3_AWS)
|
||||
is_enabled(ENABLE_S3_INTERNAL HAS_S3_INTERNAL)
|
||||
is_enabled(HAS_HDF5_ROS3 HAS_HDF5_ROS3)
|
||||
is_enabled(ENABLE_NCZARR HAS_NCZARR)
|
||||
is_enabled(ENABLE_NCZARR_ZIP HAS_NCZARR_ZIP)
|
||||
is_enabled(ENABLE_NCZARR_ZIP DO_NCZARR_ZIP_TESTS)
|
||||
is_enabled(NETCDF_ENABLE_NCZARR HAS_NCZARR)
|
||||
is_enabled(NETCDF_ENABLE_NCZARR_ZIP HAS_NCZARR_ZIP)
|
||||
is_enabled(NETCDF_ENABLE_NCZARR_ZIP DO_NCZARR_ZIP_TESTS)
|
||||
is_enabled(ENABLE_QUANTIZE HAS_QUANTIZE)
|
||||
is_enabled(NETCDF_ENABLE_LOGGING HAS_LOGGING)
|
||||
is_enabled(NETCDF_ENABLE_FILTER_TESTING DO_FILTER_TESTS)
|
||||
|
@ -109,7 +109,7 @@ NCPOCO = libncpoco
|
||||
endif
|
||||
|
||||
# Build Cloud Storage if desired.
|
||||
if ENABLE_NCZARR
|
||||
if NETCDF_ENABLE_NCZARR
|
||||
ZARR_TEST_DIR = nczarr_test
|
||||
ZARR = libnczarr
|
||||
endif
|
||||
|
@ -348,7 +348,7 @@ endif()
|
||||
################################
|
||||
IF (NETCDF_ENABLE_FILTER_SZIP)
|
||||
find_package(Szip)
|
||||
elseif(ENABLE_NCZARR)
|
||||
elseif(NETCDF_ENABLE_NCZARR)
|
||||
find_package(Szip)
|
||||
endif()
|
||||
IF (NETCDF_ENABLE_FILTER_BZ2)
|
||||
@ -381,7 +381,7 @@ else()
|
||||
set(STD_FILTERS "${STD_FILTERS} bz2")
|
||||
endif()
|
||||
|
||||
IF (ENABLE_NCZARR_ZIP)
|
||||
IF (NETCDF_ENABLE_NCZARR_ZIP)
|
||||
find_package(Zip REQUIRED)
|
||||
target_include_directories(netcdf
|
||||
PRIVATE
|
||||
|
@ -146,13 +146,13 @@ are set when opening a binary file on Windows. */
|
||||
#cmakedefine NETCDF_ENABLE_DAP_REMOTE_TESTS 1
|
||||
|
||||
/* if true, enable NCZARR */
|
||||
#cmakedefine ENABLE_NCZARR 1
|
||||
#cmakedefine NETCDF_ENABLE_NCZARR 1
|
||||
|
||||
/* if true, enable nczarr filter support */
|
||||
#cmakedefine ENABLE_NCZARR_FILTERS 1
|
||||
#cmakedefine NETCDF_ENABLE_NCZARR_FILTERS 1
|
||||
|
||||
/* if true, enable nczarr zip support */
|
||||
#cmakedefine ENABLE_NCZARR_ZIP 1
|
||||
#cmakedefine NETCDF_ENABLE_NCZARR_ZIP 1
|
||||
|
||||
/* if true, Allow dynamically loaded plugins */
|
||||
#cmakedefine ENABLE_PLUGINS 1
|
||||
|
16
configure.ac
16
configure.ac
@ -712,10 +712,10 @@ if test "x$enable_nczarr" = xyes ; then
|
||||
fi
|
||||
|
||||
if test "x$enable_nczarr" = xyes; then
|
||||
AC_DEFINE([ENABLE_NCZARR], [1], [if true, build NCZarr Client])
|
||||
AC_SUBST(ENABLE_NCZARR)
|
||||
AC_DEFINE([NETCDF_ENABLE_NCZARR], [1], [if true, build NCZarr Client])
|
||||
AC_SUBST(NETCDF_ENABLE_NCZARR)
|
||||
fi
|
||||
AM_CONDITIONAL(ENABLE_NCZARR, [test x$enable_nczarr = xyes])
|
||||
AM_CONDITIONAL(NETCDF_ENABLE_NCZARR, [test x$enable_nczarr = xyes])
|
||||
|
||||
##########
|
||||
# Look for Standardized libraries
|
||||
@ -877,7 +877,7 @@ else
|
||||
AC_MSG_RESULT([${enable_nczarr_zip}])
|
||||
|
||||
if test "x$enable_nczarr_zip" = xyes ; then
|
||||
AC_DEFINE([ENABLE_NCZARR_ZIP], [1], [If true, then libzip found])
|
||||
AC_DEFINE([NETCDF_ENABLE_NCZARR_ZIP], [1], [If true, then libzip found])
|
||||
fi
|
||||
|
||||
# Check for enabling of S3 support
|
||||
@ -1887,7 +1887,7 @@ enable_nczarr_filter_testing=no
|
||||
fi
|
||||
|
||||
if test "x$enable_nczarr_filters" = xyes; then
|
||||
AC_DEFINE([ENABLE_NCZARR_FILTERS], [1], [if true, enable NCZarr filters])
|
||||
AC_DEFINE([NETCDF_ENABLE_NCZARR_FILTERS], [1], [if true, enable NCZarr filters])
|
||||
fi
|
||||
|
||||
# Client side filter registration is permanently disabled
|
||||
@ -1895,7 +1895,7 @@ enable_clientside_filters=no
|
||||
|
||||
AM_CONDITIONAL(ENABLE_CLIENTSIDE_FILTERS, [test x$enable_clientside_filters = xyes])
|
||||
AM_CONDITIONAL(NETCDF_ENABLE_FILTER_TESTING, [test x$enable_filter_testing = xyes])
|
||||
AM_CONDITIONAL(ENABLE_NCZARR_FILTERS, [test x$enable_nczarr_filters = xyes])
|
||||
AM_CONDITIONAL(NETCDF_ENABLE_NCZARR_FILTERS, [test x$enable_nczarr_filters = xyes])
|
||||
|
||||
# Automake conditionals need to be called, whether the answer is yes
|
||||
# or no.
|
||||
@ -1933,10 +1933,10 @@ AM_CONDITIONAL(HAS_PAR_FILTERS, [test x$hdf5_supports_par_filters = xyes ])
|
||||
AM_CONDITIONAL(ENABLE_S3, [test "x$enable_s3" = xyes])
|
||||
AM_CONDITIONAL(ENABLE_S3_AWS, [test "x$enable_s3_aws" = xyes])
|
||||
AM_CONDITIONAL(ENABLE_S3_INTERNAL, [test "x$enable_s3_internal" = xyes])
|
||||
AM_CONDITIONAL(ENABLE_NCZARR, [test "x$enable_nczarr" = xyes])
|
||||
AM_CONDITIONAL(NETCDF_ENABLE_NCZARR, [test "x$enable_nczarr" = xyes])
|
||||
AM_CONDITIONAL(ENABLE_S3_TESTPUB, [test "x$with_s3_testing" != xno]) # all => public
|
||||
AM_CONDITIONAL(ENABLE_S3_TESTALL, [test "x$with_s3_testing" = xyes])
|
||||
AM_CONDITIONAL(ENABLE_NCZARR_ZIP, [test "x$enable_nczarr_zip" = xyes])
|
||||
AM_CONDITIONAL(NETCDF_ENABLE_NCZARR_ZIP, [test "x$enable_nczarr_zip" = xyes])
|
||||
AM_CONDITIONAL(HAVE_DEFLATE, [test "x$have_deflate" = xyes])
|
||||
AM_CONDITIONAL(HAVE_SZ, [test "x$have_sz" = xyes])
|
||||
AM_CONDITIONAL(HAVE_H5Z_SZIP, [test "x$enable_hdf5_szip" = xyes])
|
||||
|
@ -503,7 +503,7 @@ The relevant ./configure options are as follows.
|
||||
|
||||
The relevant CMake flags are as follows.
|
||||
|
||||
1. *-DENABLE_NCZARR=off* -- equivalent to the Automake *--disable-nczarr* option.
|
||||
1. *-DNETCDF_ENABLE_NCZARR=off* -- equivalent to the Automake *--disable-nczarr* option.
|
||||
## Testing NCZarr S3 Support {#nczarr_testing_S3_support}
|
||||
|
||||
The relevant tests for S3 support are in the _nczarr_test_ directory.
|
||||
|
@ -138,7 +138,7 @@ extern int HDF4_initialize(void);
|
||||
extern int HDF4_finalize(void);
|
||||
#endif
|
||||
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
extern const NC_Dispatch* NCZ_dispatch_table;
|
||||
extern int NCZ_initialize(void);
|
||||
extern int NCZ_finalize(void);
|
||||
|
@ -13,7 +13,7 @@ if USE_DAP
|
||||
AM_CPPFLAGS += -I${top_srcdir}/oc2
|
||||
endif
|
||||
|
||||
if ENABLE_NCZARR
|
||||
if NETCDF_ENABLE_NCZARR
|
||||
AM_CPPFLAGS += -I${top_srcdir}/libnczarr
|
||||
endif
|
||||
|
||||
|
@ -84,9 +84,9 @@ if (ENABLE_PNETCDF)
|
||||
target_link_libraries(dispatch PUBLIC PNETCDF::PNETCDF)
|
||||
endif()
|
||||
|
||||
IF(ENABLE_NCZARR)
|
||||
IF(NETCDF_ENABLE_NCZARR)
|
||||
target_include_directories(dispatch PUBLIC ../libnczarr)
|
||||
endif(ENABLE_NCZARR)
|
||||
endif(NETCDF_ENABLE_NCZARR)
|
||||
|
||||
if(ENABLE_S3)
|
||||
if(ENABLE_S3_AWS)
|
||||
|
@ -1909,7 +1909,7 @@ NC_create(const char *path0, int cmode, size_t initialsz,
|
||||
dispatcher = UDF1_dispatch_table;
|
||||
break;
|
||||
#endif /* USE_NETCDF4 */
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
case NC_FORMATX_NCZARR:
|
||||
dispatcher = NCZ_dispatch_table;
|
||||
break;
|
||||
@ -2050,7 +2050,7 @@ NC_open(const char *path0, int omode, int basepe, size_t *chunksizehintp,
|
||||
#ifdef NETCDF_ENABLE_CDF5
|
||||
cdf5built = 1;
|
||||
#endif
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
nczarrbuilt = 1;
|
||||
#endif
|
||||
if(UDF0_dispatch_table != NULL)
|
||||
@ -2081,7 +2081,7 @@ NC_open(const char *path0, int omode, int basepe, size_t *chunksizehintp,
|
||||
#ifdef USE_HDF4
|
||||
| (1<<NC_FORMATX_NC_HDF4)
|
||||
#endif
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
| (1<<NC_FORMATX_NCZARR)
|
||||
#endif
|
||||
#ifdef NETCDF_ENABLE_DAP
|
||||
@ -2121,7 +2121,7 @@ NC_open(const char *path0, int omode, int basepe, size_t *chunksizehintp,
|
||||
dispatcher = NCD4_dispatch_table;
|
||||
break;
|
||||
#endif
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
case NC_FORMATX_NCZARR:
|
||||
dispatcher = NCZ_dispatch_table;
|
||||
break;
|
||||
|
@ -25,7 +25,7 @@
|
||||
#include "hdf5internal.h"
|
||||
#endif
|
||||
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
#include "zdispatch.h"
|
||||
#endif
|
||||
|
||||
|
@ -58,7 +58,7 @@ if(NETCDF_ENABLE_DAP4)
|
||||
)
|
||||
endif()
|
||||
|
||||
if(ENABLE_NCZARR)
|
||||
if(NETCDF_ENABLE_NCZARR)
|
||||
target_sources(netcdf
|
||||
PRIVATE
|
||||
$<TARGET_OBJECTS:nczarr>
|
||||
@ -114,7 +114,7 @@ set(TLL_LIBS ${TLL_LIBS} ${HAVE_LIBM} ${ZLIB_LIBRARY})
|
||||
# Add extra dependencies specified via NC_EXTRA_DEPS
|
||||
set(TLL_LIBS ${TLL_LIBS} ${EXTRA_DEPS})
|
||||
|
||||
if(ENABLE_NCZARR_ZIP)
|
||||
if(NETCDF_ENABLE_NCZARR_ZIP)
|
||||
set(TLL_LIBS ${TLL_LIBS} ${Zip_LIBRARIES})
|
||||
endif()
|
||||
|
||||
@ -135,7 +135,7 @@ if(HAVE_LIBDL)
|
||||
set(TLL_LIBS ${LIBDL} ${TLL_LIBS})
|
||||
endif()
|
||||
|
||||
if(ENABLE_NCZARR_ZIP)
|
||||
if(NETCDF_ENABLE_NCZARR_ZIP)
|
||||
set(TLL_LIBS ${TLL_LIBS} ${Zip_LIBRARIES})
|
||||
endif()
|
||||
|
||||
|
@ -79,13 +79,13 @@ AM_CPPFLAGS += -I${top_srcdir}/libsrc4
|
||||
libnetcdf_la_LIBADD += ${top_builddir}/libsrc4/libnetcdf4.la
|
||||
endif #USE_NETCDF4
|
||||
|
||||
if ENABLE_NCZARR
|
||||
if NETCDF_ENABLE_NCZARR
|
||||
AM_CPPFLAGS += -I${top_srcdir}/libnczarr
|
||||
libnetcdf_la_LIBADD += ${top_builddir}/libnczarr/libnczarr.la
|
||||
if ENABLE_S3_AWS
|
||||
libnetcdf_la_LIBADD += ${aws_cpp_sdk_core_LIBS} ${aws_cpp_sdk_s3_LIBS}
|
||||
endif
|
||||
endif #ENABLE_NCZARR
|
||||
endif #NETCDF_ENABLE_NCZARR
|
||||
|
||||
if ENABLE_PLUGINS
|
||||
AM_CPPFLAGS += -I${top_srcdir}/libncpoco
|
||||
|
@ -112,7 +112,7 @@ nc_initialize()
|
||||
#ifdef ENABLE_S3
|
||||
if((stat = NC_s3sdkinitialize())) goto done;
|
||||
#endif
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
if((stat = NCZ_initialize())) goto done;
|
||||
#endif
|
||||
|
||||
@ -170,7 +170,7 @@ nc_finalize(void)
|
||||
if((stat = NC_HDF5_finalize())) failed = stat;
|
||||
#endif
|
||||
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
if((stat = NCZ_finalize())) failed = stat;
|
||||
#endif
|
||||
|
||||
|
@ -46,7 +46,7 @@ zfilter.h
|
||||
zdebug.h
|
||||
)
|
||||
|
||||
if(ENABLE_NCZARR_ZIP)
|
||||
if(NETCDF_ENABLE_NCZARR_ZIP)
|
||||
set(libnczarr_SOURCES ${libnczarr_SOURCES} zmap_zip.c)
|
||||
endif()
|
||||
|
||||
|
@ -15,7 +15,7 @@ AM_CXXFLAGS =
|
||||
libnczarr_la_LIBADD =
|
||||
libnczarr_la_LDFLAGS =
|
||||
|
||||
# Remember ENABLE_NCZARR implies USE_NETCDF4
|
||||
# Remember NETCDF_ENABLE_NCZARR implies USE_NETCDF4
|
||||
|
||||
# We may have to add to these later.
|
||||
DISTCLEANFILES =
|
||||
@ -64,11 +64,11 @@ zprovenance.h \
|
||||
zfilter.h \
|
||||
zdebug.h
|
||||
|
||||
if ENABLE_NCZARR_ZIP
|
||||
if NETCDF_ENABLE_NCZARR_ZIP
|
||||
libnczarr_la_SOURCES += zmap_zip.c
|
||||
endif
|
||||
|
||||
if ENABLE_NCZARR_FILTERS
|
||||
if NETCDF_ENABLE_NCZARR_FILTERS
|
||||
libnczarr_la_SOURCES += zfilter.c
|
||||
endif
|
||||
|
||||
|
@ -102,7 +102,7 @@ ncz_get_att_special(NC_FILE_INFO_T* h5, NC_VAR_INFO_T* var, const char* name,
|
||||
|
||||
/* Handle the per-var case(s) first */
|
||||
if(var != NULL) {
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
if(strcmp(name,NC_ATT_CODECS)==0) {
|
||||
NClist* filters = (NClist*)var->filters;
|
||||
|
||||
|
@ -161,7 +161,7 @@ NCZ_zclose_var1(NC_VAR_INFO_T* var)
|
||||
nullfree(zatt);
|
||||
att->format_att_info = NULL; /* avoid memory errors */
|
||||
}
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
/* Reclaim filters */
|
||||
if(var->filters != NULL) {
|
||||
(void)NCZ_filter_freelists(var);
|
||||
|
@ -157,7 +157,7 @@ NCZ_show_metadata(int ncid)
|
||||
return NC_NOERR;
|
||||
}
|
||||
|
||||
#ifndef ENABLE_NCZARR_FILTERS
|
||||
#ifndef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
int
|
||||
NCZ_def_var_filter(int ncid, int varid, unsigned int id , size_t n , const unsigned int *params)
|
||||
{
|
||||
@ -199,7 +199,7 @@ NCZ_inq_filter_avail(int ncid, unsigned id)
|
||||
}
|
||||
|
||||
|
||||
#endif /*ENABLE_NCZARR_FILTERS*/
|
||||
#endif /*NETCDF_ENABLE_NCZARR_FILTERS*/
|
||||
|
||||
/**************************************************/
|
||||
/* Following functions call into libsrc4 */
|
||||
|
@ -523,7 +523,7 @@ nc_var_filter_remove(int ncid, int varid, unsigned int filterid)
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
int
|
||||
NCZ_def_var_filter(int ncid, int varid, unsigned int id, size_t nparams,
|
||||
const unsigned int* params)
|
||||
@ -743,7 +743,7 @@ done:
|
||||
return ZUNTRACE(stat);
|
||||
}
|
||||
|
||||
#endif /*ENABLE_NCZARR_FILTERS*/
|
||||
#endif /*NETCDF_ENABLE_NCZARR_FILTERS*/
|
||||
|
||||
/**************************************************/
|
||||
/* Filter application functions */
|
||||
@ -760,7 +760,7 @@ NCZ_filter_initialize(void)
|
||||
codec_defaults = nclistnew();
|
||||
NCZ_filter_initialized = 1;
|
||||
memset(loaded_plugins,0,sizeof(loaded_plugins));
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
if((stat = NCZ_load_all_plugins())) goto done;
|
||||
#endif
|
||||
|
||||
@ -775,7 +775,7 @@ NCZ_filter_finalize(void)
|
||||
int i;
|
||||
ZTRACE(6,"");
|
||||
if(!NCZ_filter_initialized) goto done;
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
/* Reclaim all loaded filters */
|
||||
#ifdef DEBUGL
|
||||
fprintf(stderr,">>> DEBUGL: finalize reclaim:\n");
|
||||
|
@ -82,7 +82,7 @@ NCZ_finalize_internal(void)
|
||||
{
|
||||
/* Reclaim global resources */
|
||||
ncz_initialized = 0;
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
NCZ_filter_finalize();
|
||||
#endif
|
||||
#ifdef ENABLE_S3
|
||||
|
@ -19,7 +19,7 @@ nczmap_features(NCZM_IMPL impl)
|
||||
{
|
||||
switch (impl) {
|
||||
case NCZM_FILE: return zmap_file.features;
|
||||
#ifdef ENABLE_NCZARR_ZIP
|
||||
#ifdef NETCDF_ENABLE_NCZARR_ZIP
|
||||
case NCZM_ZIP: return zmap_zip.features;
|
||||
#endif
|
||||
#ifdef ENABLE_S3
|
||||
@ -52,7 +52,7 @@ nczmap_create(NCZM_IMPL impl, const char *path, int mode, size64_t flags, void*
|
||||
stat = zmap_file.create(path, mode, flags, parameters, &map);
|
||||
if(stat) goto done;
|
||||
break;
|
||||
#ifdef ENABLE_NCZARR_ZIP
|
||||
#ifdef NETCDF_ENABLE_NCZARR_ZIP
|
||||
case NCZM_ZIP:
|
||||
stat = zmap_zip.create(path, mode, flags, parameters, &map);
|
||||
if(stat) goto done;
|
||||
@ -90,7 +90,7 @@ nczmap_open(NCZM_IMPL impl, const char *path, int mode, size64_t flags, void* pa
|
||||
stat = zmap_file.open(path, mode, flags, parameters, &map);
|
||||
if(stat) goto done;
|
||||
break;
|
||||
#ifdef ENABLE_NCZARR_ZIP
|
||||
#ifdef NETCDF_ENABLE_NCZARR_ZIP
|
||||
case NCZM_ZIP:
|
||||
stat = zmap_zip.open(path, mode, flags, parameters, &map);
|
||||
if(stat) goto done;
|
||||
@ -122,7 +122,7 @@ nczmap_truncate(NCZM_IMPL impl, const char *path)
|
||||
case NCZM_FILE:
|
||||
if((stat = zmap_file.truncate(path))) goto done;
|
||||
break;
|
||||
#ifdef ENABLE_NCZARR_ZIP
|
||||
#ifdef NETCDF_ENABLE_NCZARR_ZIP
|
||||
case NCZM_ZIP:
|
||||
if((stat = zmap_zip.truncate(path))) goto done;
|
||||
break;
|
||||
|
@ -217,7 +217,7 @@ extern NCZMAP_DS_API zmap_file;
|
||||
#ifdef USE_HDF5
|
||||
extern NCZMAP_DS_API zmap_nz4;
|
||||
#endif
|
||||
#ifdef ENABLE_NCZARR_ZIP
|
||||
#ifdef NETCDF_ENABLE_NCZARR_ZIP
|
||||
extern NCZMAP_DS_API zmap_zip;
|
||||
#endif
|
||||
#ifdef ENABLE_S3
|
||||
|
@ -296,7 +296,7 @@ ncz_sync_var_meta(NC_FILE_INFO_T* file, NC_VAR_INFO_T* var, int isclose)
|
||||
int purezarr = 0;
|
||||
size64_t shape[NC_MAX_VAR_DIMS];
|
||||
NCZ_VAR_INFO_T* zvar = var->format_var_info;
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
NClist* filterchain = NULL;
|
||||
NCjson* jfilter = NULL;
|
||||
#endif
|
||||
@ -316,7 +316,7 @@ ncz_sync_var_meta(NC_FILE_INFO_T* file, NC_VAR_INFO_T* var, int isclose)
|
||||
if((stat = NCZ_adjust_var_cache(var))) goto done;
|
||||
/* rebuild the fill chunk */
|
||||
if((stat = NCZ_ensure_fill_chunk(zvar->cache))) goto done;
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
/* Build the filter working parameters for any filters */
|
||||
if((stat = NCZ_filter_setup(var))) goto done;
|
||||
#endif
|
||||
@ -413,7 +413,7 @@ ncz_sync_var_meta(NC_FILE_INFO_T* file, NC_VAR_INFO_T* var, int isclose)
|
||||
/* From V2 Spec: A JSON object identifying the primary compression codec and providing
|
||||
configuration parameters, or ``null`` if no compressor is to be used. */
|
||||
if((stat = NCJaddstring(jvar,NCJ_STRING,"compressor"))) goto done;
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
filterchain = (NClist*)var->filters;
|
||||
if(nclistlength(filterchain) > 0) {
|
||||
struct NCZ_Filter* filter = (struct NCZ_Filter*)nclistget(filterchain,nclistlength(filterchain)-1);
|
||||
@ -435,7 +435,7 @@ ncz_sync_var_meta(NC_FILE_INFO_T* file, NC_VAR_INFO_T* var, int isclose)
|
||||
/* A list of JSON objects providing codec configurations, or ``null``
|
||||
if no filters are to be applied. */
|
||||
if((stat = NCJaddstring(jvar,NCJ_STRING,"filters"))) goto done;
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
if(nclistlength(filterchain) > 1) {
|
||||
size_t k;
|
||||
/* jtmp holds the array of filters */
|
||||
@ -1486,7 +1486,7 @@ define_vars(NC_FILE_INFO_T* file, NC_GRP_INFO_T* grp, NClist* varnames)
|
||||
int vtypelen = 0;
|
||||
int rank = 0;
|
||||
int zarr_rank = 0; /* Need to watch out for scalars */
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
NCjson* jfilter = NULL;
|
||||
int chainindex = 0;
|
||||
#endif
|
||||
@ -1736,7 +1736,7 @@ define_vars(NC_FILE_INFO_T* file, NC_GRP_INFO_T* grp, NClist* varnames)
|
||||
object MUST contain a "id" key identifying the codec to be used. */
|
||||
/* Do filters key before compressor key so final filter chain is in correct order */
|
||||
{
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
if(var->filters == NULL) var->filters = (void*)nclistnew();
|
||||
if(zvar->incompletefilters == NULL) zvar->incompletefilters = (void*)nclistnew();
|
||||
chainindex = 0; /* track location of filter in the chain */
|
||||
@ -1759,7 +1759,7 @@ define_vars(NC_FILE_INFO_T* file, NC_GRP_INFO_T* grp, NClist* varnames)
|
||||
/* compressor key */
|
||||
/* From V2 Spec: A JSON object identifying the primary compression codec and providing
|
||||
configuration parameters, or ``null`` if no compressor is to be used. */
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
{
|
||||
if(var->filters == NULL) var->filters = (void*)nclistnew();
|
||||
if((stat = NCZ_filter_initialize())) goto done;
|
||||
@ -1783,7 +1783,7 @@ define_vars(NC_FILE_INFO_T* file, NC_GRP_INFO_T* grp, NClist* varnames)
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
if(!suppress) {
|
||||
/* At this point, we can finalize the filters */
|
||||
if((stat = NCZ_filter_setup(var))) goto done;
|
||||
|
@ -389,7 +389,7 @@ NCZ_def_var(int ncid, const char *name, nc_type xtype, int ndims,
|
||||
var->meta_read = NC_TRUE;
|
||||
var->atts_read = NC_TRUE;
|
||||
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
/* Set the filter list */
|
||||
assert(var->filters == NULL);
|
||||
var->filters = (void*)nclistnew();
|
||||
@ -558,7 +558,7 @@ ncz_def_var_extra(int ncid, int varid, int *shuffle, int *unused1,
|
||||
|
||||
/* Can't turn on parallel and deflate/fletcher32/szip/shuffle
|
||||
* before HDF5 1.10.3. */
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
#ifndef HDF5_SUPPORTS_PAR_FILTERS
|
||||
if (h5->parallel == NC_TRUE)
|
||||
if (nclistlength(((NClist*)var->filters)) > 0 || fletcher32 || shuffle)
|
||||
|
@ -675,7 +675,7 @@ put_chunk(NCZChunkCache* cache, NCZCacheEntry* entry)
|
||||
}
|
||||
|
||||
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
/* Make sure the entry is in filtered state */
|
||||
if(!entry->isfiltered) {
|
||||
NC_VAR_INFO_T* var = cache->var;
|
||||
@ -792,7 +792,7 @@ get_chunk(NCZChunkCache* cache, NCZCacheEntry* entry)
|
||||
if((stat = NCZ_copy_data(file,cache->var,cache->fillchunk,cache->chunkcount,ZREADING,entry->data))) goto done;
|
||||
stat = NC_NOERR;
|
||||
}
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
/* Make sure the entry is in unfiltered state */
|
||||
if(!empty && entry->isfiltered) {
|
||||
NC_VAR_INFO_T* var = cache->var;
|
||||
|
@ -102,7 +102,7 @@ else
|
||||
has_parallel="yes"
|
||||
fi
|
||||
|
||||
has_nczarr="@ENABLE_NCZARR@"
|
||||
has_nczarr="@NETCDF_ENABLE_NCZARR@"
|
||||
if [ -z "$has_nczarr" -o "$has_nczarr" = "OFF" -o "$has_nczarr" = "FALSE" ]; then
|
||||
has_nczarr="no"
|
||||
else
|
||||
|
@ -1333,7 +1333,7 @@ main(int argc, char **argv)
|
||||
if (nc_def_var_quantize(ncid, varid2, NC_QUANTIZE_BITGROOM, NSD_3)) ERR;
|
||||
|
||||
#ifdef TESTNCZARR
|
||||
#ifdef ENABLE_NCZARR_FILTERS
|
||||
#ifdef NETCDF_ENABLE_NCZARR_FILTERS
|
||||
/* Set up zlib compression. This will work better because the
|
||||
* data are quantized, yielding a smaller output file. We will
|
||||
* set compression level to 1, which is usually the best
|
||||
|
@ -84,7 +84,7 @@ getformat(const char* sformat)
|
||||
#ifdef USE_HDF5
|
||||
return NC_FORMATX_NC4;
|
||||
#else
|
||||
# ifdef ENABLE_NCZARR
|
||||
# ifdef NETCDF_ENABLE_NCZARR
|
||||
return NC_FORMATX_NCZARR;
|
||||
# endif
|
||||
#endif
|
||||
|
@ -200,7 +200,7 @@ IF(ENABLE_TESTS)
|
||||
add_sh_test(nczarr_test run_fillonlyz)
|
||||
ENDIF()
|
||||
|
||||
IF(ENABLE_NCZARR_FILTERS)
|
||||
IF(NETCDF_ENABLE_NCZARR_FILTERS)
|
||||
IF(NETCDF_ENABLE_FILTER_TESTING)
|
||||
build_bin_test(test_nczfilter)
|
||||
build_bin_test(test_filter_vlen)
|
||||
@ -219,9 +219,9 @@ IF(ENABLE_TESTS)
|
||||
ADD_SH_TEST(nczarr_test run_unknown)
|
||||
ENDIF(FALSE)
|
||||
ENDIF(NETCDF_ENABLE_FILTER_TESTING)
|
||||
ENDIF(ENABLE_NCZARR_FILTERS)
|
||||
ENDIF(NETCDF_ENABLE_NCZARR_FILTERS)
|
||||
|
||||
if(ENABLE_NCZARR_ZIP)
|
||||
if(NETCDF_ENABLE_NCZARR_ZIP)
|
||||
add_sh_test(nczarr_test run_newformat)
|
||||
# Test various corrupted files
|
||||
ADD_SH_TEST(nczarr_test run_corrupt.sh)
|
||||
|
@ -104,7 +104,7 @@ endif #NETCDF_BUILD_UTILITIES
|
||||
|
||||
if NETCDF_BUILD_UTILITIES
|
||||
|
||||
if ENABLE_NCZARR_ZIP
|
||||
if NETCDF_ENABLE_NCZARR_ZIP
|
||||
TESTS += run_newformat.sh
|
||||
endif
|
||||
|
||||
@ -136,7 +136,7 @@ endif
|
||||
|
||||
endif # BUILD_BENCHMARKS
|
||||
|
||||
if ENABLE_NCZARR_FILTERS
|
||||
if NETCDF_ENABLE_NCZARR_FILTERS
|
||||
if NETCDF_ENABLE_FILTER_TESTING
|
||||
|
||||
check_PROGRAMS += test_filter_avail test_filter_vlen
|
||||
@ -162,7 +162,7 @@ XFAIL_TESTS = run_filter.sh run_specific_filters.sh run_nczfilter.sh
|
||||
endif # ISMINGW
|
||||
|
||||
endif #NETCDF_ENABLE_FILTER_TESTING
|
||||
endif #ENABLE_NCZARR_FILTERS
|
||||
endif #NETCDF_ENABLE_NCZARR_FILTERS
|
||||
|
||||
# Test various corrupted files
|
||||
TESTS += run_corrupt.sh
|
||||
|
@ -28,7 +28,7 @@
|
||||
#include <H5DSpublic.h>
|
||||
#endif
|
||||
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
#include "zincludes.h"
|
||||
#endif
|
||||
|
||||
@ -38,7 +38,7 @@
|
||||
#ifdef USE_HDF5
|
||||
#define H5
|
||||
#endif
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
#define NZ
|
||||
#endif
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
#include "ncpathmgr.h"
|
||||
#include "nclist.h"
|
||||
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
#include "zincludes.h"
|
||||
#endif
|
||||
|
||||
|
@ -9,7 +9,7 @@
|
||||
#include "ncpathmgr.h"
|
||||
#include "nclist.h"
|
||||
|
||||
#ifdef ENABLE_NCZARR
|
||||
#ifdef NETCDF_ENABLE_NCZARR
|
||||
#include "zincludes.h"
|
||||
#endif
|
||||
|
||||
|
@ -133,7 +133,7 @@ endif()
|
||||
if(Blosc_FOUND)
|
||||
installplugin(h5blosc)
|
||||
endif()
|
||||
if(ENABLE_NCZARR)
|
||||
if(NETCDF_ENABLE_NCZARR)
|
||||
installplugin(h5fletcher32)
|
||||
installplugin(h5shuffle)
|
||||
installplugin(h5deflate)
|
||||
|
@ -76,7 +76,7 @@ lib__nch5zstd_la_SOURCES = H5Zzstd.c H5Zzstd.h
|
||||
plugins_to_install += lib__nch5zstd.la
|
||||
endif
|
||||
|
||||
if ENABLE_NCZARR_FILTERS
|
||||
if NETCDF_ENABLE_NCZARR_FILTERS
|
||||
# The NCZarr codec libraries (they need libnetcdf)
|
||||
lib__nczstdfilters_la_SOURCES = NCZstdfilters.c
|
||||
lib__nczstdfilters_la_LIBADD = $(LIBADD) $(top_builddir)/liblib/libnetcdf.la
|
||||
|
Loading…
x
Reference in New Issue
Block a user