diff --git a/CMakeLists.txt b/CMakeLists.txt index befa94ed7..76667583c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -26,13 +26,13 @@ set(PACKAGE "netCDF" CACHE STRING "") SET(NC_VERSION_MAJOR 4) SET(NC_VERSION_MINOR 5) -SET(NC_VERSION_PATCH 0) +SET(NC_VERSION_PATCH 1) SET(NC_VERSION_NOTE "-development") SET(netCDF_VERSION ${NC_VERSION_MAJOR}.${NC_VERSION_MINOR}.${NC_VERSION_PATCH}${NC_VERSION_NOTE}) SET(VERSION ${netCDF_VERSION}) SET(NC_VERSION ${netCDF_VERSION}) -SET(netCDF_LIB_VERSION 11.4.0) -SET(netCDF_SO_VERSION 11) +SET(netCDF_LIB_VERSION 13) +SET(netCDF_SO_VERSION 13) SET(PACKAGE_VERSION ${VERSION}) # Get system configuration, Use it to determine osname, os release, cpu. These diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index af1532013..64fe650bc 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -5,24 +5,27 @@ Release Notes {#RELEASE_NOTES} This file contains a high-level description of this package's evolution. Releases are in reverse chronological order (most recent first). Note that, as of netcdf 4.2, the `netcdf-c++` and `netcdf-fortran` libraries have been separated into their own libraries. -## 4.5 - TBD +## 4.5.0 - TBD + +### 4.5.0-rc1 - June 2, 2017 -* [Bug Fix] Corrected an issue where 'make check' would fail if 'make' or 'make all' had not run first. See [Github #339](https://github.com/Unidata/netcdf-c/issues/339) for more information. -* [Bug Fix] Corrected an issue on Windows with Large file tests. See [Github #385](https://github.com/Unidata/netcdf-c/issues/385]) for more information. -* [Bug Fix] Corrected an issue with diskless file access, see [Pull Request #400](https://github.com/Unidata/netcdf-c/issues/400) and [Pull Request #403](https://github.com/Unidata/netcdf-c/issues/403) for more information. * [Enhancement] DAP4 is now included. Since dap2 is the default for urls, dap4 must be specified by (1) using "dap4:" as the url protocol, or (2) appending "#protocol=dap4" to the end of the url, or (3) appending "#dap4" to the end of the url Note that dap4 is enabled by default but remote-testing is disbled until the testserver situation is resolved. -* [Enhancement] The remote testing server can now be specified with the '--with-testserver" option to ./configure. +* [Enhancement] The remote testing server can now be specified with the `--with-testserver` option to ./configure. +* [Enhancement] Modified netCDF4 to use ASCII for NC_CHAR. See [Github Pull request #316](https://github.com/Unidata/netcdf-c/pull/316) for more information. +* [Bug Fix] Corrected an error with how dimsizes might be read. See [Github #410](https://github.com/unidata/netcdf-c/issues/410) for more information. +* [Bug Fix] Corrected an issue where 'make check' would fail if 'make' or 'make all' had not run first. See [Github #339](https://github.com/Unidata/netcdf-c/issues/339) for more information. +* [Bug Fix] Corrected an issue on Windows with Large file tests. See [Github #385](https://github.com/Unidata/netcdf-c/issues/385]) for more information. +* [Bug Fix] Corrected an issue with diskless file access, see [Pull Request #400](https://github.com/Unidata/netcdf-c/issues/400) and [Pull Request #403](https://github.com/Unidata/netcdf-c/issues/403) for more information. * [Upgrade] The bash based test scripts have been upgraded to use a common test_common.sh include file that isolates build specific information. * [Upgrade] The bash based test scripts have been upgraded to use a common test_common.sh include file that isolates build specific information. * [Refactor] the oc2 library is no longer independent of the main netcdf-c library. For example, it now uses ncuri, nclist, and ncbytes instead of its homegrown equivalents. * [Bug Fix] `NC_EGLOBAL` is now properly returned when attempting to set a global `_FillValue` attribute. See [GitHub #388](https://github.com/Unidata/netcdf-c/issues/388) and [GitHub #389](https://github.com/Unidata/netcdf-c/issues/389) for more information. * [Bug Fix] Corrected an issue where data loss would occur when `_FillValue` was mistakenly allowed to be redefined. See [Github #390](https://github.com/Unidata/netcdf-c/issues/390), [GitHub #387](https://github.com/Unidata/netcdf-c/pull/387) for more information. -* [Enhancement] Modified netCDF4 to use ASCII for NC_CHAR. See [Github Pull request #316](https://github.com/Unidata/netcdf-c/pull/316) for more information. * [Upgrade][Bug] Corrected an issue regarding how "orphaned" DAS attributes were handled. See [GitHub #376](https://github.com/Unidata/netcdf-c/pull/376) for more information. * [Upgrade] Update utf8proc.[ch] to use the version now maintained by the Julia Language project (https://github.com/JuliaLang/utf8proc/blob/master/LICENSE.md). * [Bug] Addressed conversion problem with Windows sscanf. This primarily affected some OPeNDAP URLs on Windows. See [GitHub #365](https://github.com/Unidata/netcdf-c/issues/365) and [GitHub #366](https://github.com/Unidata/netcdf-c/issues/366) for more information. diff --git a/config.h.cmake.in b/config.h.cmake.in index c1bf7fa7f..0db40ccd2 100644 --- a/config.h.cmake.in +++ b/config.h.cmake.in @@ -3,6 +3,18 @@ #ifdef _MSC_VER +/* Prevent an issue where there is a circular inclusion + of winsock.h/windows.h. This weird state occurs with + libdap4 and hdf4 support. The solution comes from the + following URL, found after a bit of research. + + Added in support of the 4.5.0-rc1. Hello, future generations. + + * https://stackoverflow.com/questions/1372480/c-redefinition-header-files-winsock2-h + + */ + #define _WINSOCKAPI_ + #if _MSC_VER>=1900 #define STDC99 #endif diff --git a/configure.ac b/configure.ac index 92349ccf1..6b3c86ba5 100644 --- a/configure.ac +++ b/configure.ac @@ -15,7 +15,7 @@ AC_REVISION([$Id: configure.ac,v 1.450 2010/05/28 19:42:47 dmh Exp $]) AC_PREREQ([2.59]) # Initialize with name, version, and support email address. -AC_INIT([netCDF], [4.5.0-development], [support-netcdf@unidata.ucar.edu]) +AC_INIT([netCDF], [4.5.1-development], [support-netcdf@unidata.ucar.edu]) ## # Prefer an empty CFLAGS variable instead of the default -g -O2. @@ -26,7 +26,7 @@ AC_INIT([netCDF], [4.5.0-development], [support-netcdf@unidata.ucar.edu]) AC_SUBST([NC_VERSION_MAJOR]) NC_VERSION_MAJOR=4 AC_SUBST([NC_VERSION_MINOR]) NC_VERSION_MINOR=5 -AC_SUBST([NC_VERSION_PATCH]) NC_VERSION_PATCH=0 +AC_SUBST([NC_VERSION_PATCH]) NC_VERSION_PATCH=1 AC_SUBST([NC_VERSION_NOTE]) NC_VERSION_NOTE="-development" ##### @@ -71,6 +71,9 @@ AC_CONFIG_LINKS([nc_test4/ref_hdf5_compat1.nc:nc_test4/ref_hdf5_compat1.nc]) AC_CONFIG_LINKS([nc_test4/ref_hdf5_compat2.nc:nc_test4/ref_hdf5_compat2.nc]) AC_CONFIG_LINKS([nc_test4/ref_hdf5_compat3.nc:nc_test4/ref_hdf5_compat3.nc]) +AC_CONFIG_LINKS([nc_test4/ref_chunked.hdf4:nc_test4/ref_chunked.hdf4]) +AC_CONFIG_LINKS([nc_test4/ref_contiguous.hdf4:nc_test4/ref_contiguous.hdf4]) + # This call is required by automake. AM_INIT_AUTOMAKE([foreign dist-zip subdir-objects]) @@ -1439,6 +1442,7 @@ abs_top_builddir=`pwd` cd $srcdir abs_top_srcdir=`pwd` cd $abs_top_builddir +#AC_CONFIG_FILES(test_common.sh.in) rm -f ${abs_top_builddir}/test_common.sh sed -e "s|@TOPSRCDIR@|${abs_top_srcdir}|" -e "s|@TOPBUILDDIR@|${abs_top_builddir}|" <${abs_top_srcdir}/test_common.in >${abs_top_builddir}/test_common.sh @@ -1485,4 +1489,6 @@ AC_CONFIG_FILES([Makefile [test -f nc-config && chmod 755 nc-config]) AC_OUTPUT() + mv -f ${abs_top_srcdir}/test_common.sh ${abs_top_builddir}/test_common.sh + cat libnetcdf.settings diff --git a/dap4_test/test_raw.sh b/dap4_test/test_raw.sh index 9eb948d06..5d0c2706b 100755 --- a/dap4_test/test_raw.sh +++ b/dap4_test/test_raw.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash if test "x$srcdir" = x ; then srcdir=`pwd`; fi . ../test_common.sh diff --git a/docs/Doxyfile.developer b/docs/Doxyfile.developer index b7aa33ce2..39716dcb6 100644 --- a/docs/Doxyfile.developer +++ b/docs/Doxyfile.developer @@ -38,7 +38,7 @@ PROJECT_NAME = netCDF-C # could be handy for archiving the generated documentation or if some version # control system is used. -PROJECT_NUMBER = 4.4.1-development +PROJECT_NUMBER = 4.5.1-development # Using the PROJECT_BRIEF tag one can provide an optional one line description # for a project that appears at the top of each page and should give viewer a diff --git a/gdb-branch.txt b/gdb-branch.txt deleted file mode 100644 index c5561c28a..000000000 --- a/gdb-branch.txt +++ /dev/null @@ -1,18 +0,0 @@ -set breakpoint pending yes -break test_nc_redef -commands -break util.c:888 if i == 6 -end - -#break util.c:903 if i == 6 -#break util.c:1020 -#break util.c:1014 if i == 6 && j == 0 -#break util.c:1016 if i == 6 && j == 0 -#commands -#break putget.c:10948 -#end - -#break test_write.c:216 -#commands -#break ncx_put_int_double -#end diff --git a/gdb-master.txt b/gdb-master.txt deleted file mode 100644 index 9b9550d62..000000000 --- a/gdb-master.txt +++ /dev/null @@ -1,12 +0,0 @@ -set breakpoint pending yes -break test_nc_redef -commands -break util.c:835 if i == 6 -end - -#break test_write.c:139 -#break util.c:961 if i == 6 && j == 0 -#break util.c:963 if i == 6 && j == 0 -#commands -#break putget.c:10414 -#end diff --git a/gh319 Notes.md b/gh319 Notes.md deleted file mode 100644 index bc9f7ae9d..000000000 --- a/gh319 Notes.md +++ /dev/null @@ -1,10 +0,0 @@ -# Notes related to bug gh319 - -## NNotes - -## Results and Debugging Table - -Variable | Master | GH319 ----------- |--------|------ -expect | 127 | 255 -value / value[0] | 127 | -1 \ No newline at end of file diff --git a/liblib/Makefile.am b/liblib/Makefile.am index f4fb41535..5c0949de9 100644 --- a/liblib/Makefile.am +++ b/liblib/Makefile.am @@ -18,7 +18,7 @@ lib_LTLIBRARIES = libnetcdf.la # for information regarding incrementing `-version-info`. ## -libnetcdf_la_LDFLAGS = -version-info 11:4:0 ${NOUNDEFINED} +libnetcdf_la_LDFLAGS = -version-info 12:0:1 libnetcdf_la_CPPFLAGS = ${AM_CPPFLAGS} libnetcdf_la_LIBADD = diff --git a/libsrc/ncx.m4 b/libsrc/ncx.m4 index 96308cda0..219e14592 100644 --- a/libsrc/ncx.m4 +++ b/libsrc/ncx.m4 @@ -2196,9 +2196,9 @@ APIPrefix`x_get_size_t'(const void **xpp, size_t *ulp) /* similar to get_ix_int */ const uchar *cp = (const uchar *) *xpp; - *ulp = (size_t)(*cp++ << 24); - *ulp |= (size_t)(*cp++ << 16); - *ulp |= (size_t)(*cp++ << 8); + *ulp = (unsigned)(*cp++ << 24); + *ulp |= (*cp++ << 16); + *ulp |= (*cp++ << 8); *ulp |= *cp; *xpp = (const void *)((const char *)(*xpp) + X_SIZEOF_SIZE_T); diff --git a/nc_test4/CMakeLists.txt b/nc_test4/CMakeLists.txt index 12199cae9..c64a63207 100644 --- a/nc_test4/CMakeLists.txt +++ b/nc_test4/CMakeLists.txt @@ -28,8 +28,6 @@ ENDIF(BUILD_UTILITIES) BUILD_BIN_TEST(tst_empty_vlen_unlim) ADD_SH_TEST(nc_test4 run_empty_vlen_test) - - IF(NOT MSVC) SET(NC4_TESTS ${NC4_TESTS} tst_interops5 tst_camrun) ENDIF() @@ -63,7 +61,7 @@ IF(BUILD_BENCHMARKS) ENDIF() # Copy some test files from current source dir to out-of-tree build dir. -FILE(GLOB COPY_FILES ${CMAKE_CURRENT_SOURCE_DIR}/*.nc ${CMAKE_CURRENT_SOURCE_DIR}/*.sh) +FILE(GLOB COPY_FILES ${CMAKE_CURRENT_SOURCE_DIR}/*.nc ${CMAKE_CURRENT_SOURCE_DIR}/*.sh ${CMAKE_CURRENT_SOURCE_DIR}/*.hdf4) FILE(COPY ${COPY_FILES} DESTINATION ${CMAKE_CURRENT_BINARY_DIR}/) IF(MSVC) FILE(COPY ${COPY_FILES} DESTINATION ${RUNTIME_OUTPUT_DIRECTORY}/) diff --git a/nc_test4/Makefile.am b/nc_test4/Makefile.am index 90b9d8425..b6250c336 100644 --- a/nc_test4/Makefile.am +++ b/nc_test4/Makefile.am @@ -25,7 +25,7 @@ tst_h_scalar tst_rename tst_h5_endians tst_atts_string_rewrite \ tst_hdf5_file_compat tst_fill_attr_vanish tst_rehash # Temporary I hope -if !ISCYGWIN +if !ISCYGWIN NC4_TESTS += tst_h_strbug tst_h_refs endif @@ -131,12 +131,11 @@ run_get_hdf4_files.sh run_valgrind_tests.sh run_valgrind_tests2.sh \ run_bm_ar4.sh ref_tst_compounds.nc run_hdf4_valgrind_tests.sh \ ref_tst_xplatform2_1.nc ref_tst_xplatform2_2.nc ref_tst_dims.nc \ ref_tst_interops4.nc run_get_knmi_files.sh CMakeLists.txt \ -run_grp_rename.sh tst_formatx_hdf4.sh \ -run_chunk_hdf4.sh contiguous.hdf4 chunked.hdf4 \ +run_grp_rename.sh tst_formatx_hdf4.sh run_chunk_hdf4.sh \ tst_h5_endians.c tst_h4_lendian.c tst_atts_string_rewrite.c \ tst_put_vars_two_unlim_dim.c tst_empty_vlen_unlim.c run_empty_vlen_test.sh \ ref_hdf5_compat1.nc ref_hdf5_compat2.nc ref_hdf5_compat3.nc tst_misc.sh \ -tdset.h5 tst_hdf4_read_var.sh +tdset.h5 tst_hdf4_read_var.sh ref_contiguous.hdf4 ref_chunked.hdf4 CLEANFILES = tst_mpi_parallel.bin cdm_sea_soundings.nc bm_chunking.nc \ @@ -157,4 +156,6 @@ AMSR_E_L3_DailyLand_V06_20020619.hdf \ MYD29.A2009152.0000.005.2009153124331.hdf \ MYD29.A2002185.0000.005.2007160150627.hdf \ MOD29.A2000055.0005.005.2006267200024.hdf + + endif # HDF4_FILE_TESTS diff --git a/nc_test4/chunked.hdf4 b/nc_test4/ref_chunked.hdf4 similarity index 100% rename from nc_test4/chunked.hdf4 rename to nc_test4/ref_chunked.hdf4 diff --git a/nc_test4/contiguous.hdf4 b/nc_test4/ref_contiguous.hdf4 similarity index 100% rename from nc_test4/contiguous.hdf4 rename to nc_test4/ref_contiguous.hdf4 diff --git a/nc_test4/run_chunk_hdf4.sh b/nc_test4/run_chunk_hdf4.sh index 3027eba3b..5debe5fcf 100755 --- a/nc_test4/run_chunk_hdf4.sh +++ b/nc_test4/run_chunk_hdf4.sh @@ -1,37 +1,26 @@ #!/bin/sh -# Run test_chunk_hdf4 passing ${src_dir} +# Run test_chunk_hdf4 passing ${srcdir} + + if test "x$srcdir" = x ; then srcdir=`pwd`; fi . ../test_common.sh -CHUNKED=chunked.hdf4 -CONTIG=contiguous.hdf4 +set -e echo "" echo "*** Testing hdf4 chunking..." -if test "x${src_dir}" = "x" ; then -src_dir="." -fi - -# Move the data sets into place -ISDISTCHECK=0 -if test -f ./${CHUNKED} ; then -ISDISTCHECK=0 -else -ISDISTCHECK=1 -cp ${src_dir}/${CHUNKED} . -cp ${src_dir}/${CONTIG} . +if test "x${srcdir}" = "x" ; then +srcdir="." fi if ./tst_chunk_hdf4 ; then echo "***SUCCESS!! tst_chunk_hdf4" else + RES=$? echo "***FAIL: tst_chunk_hdf4" -fi - -if test "x${ISDISTCHECK}" = "x1" ; then -echo rm -f ./${CHUNKED} ./${CONTIG} + exit $RES fi exit 0 diff --git a/nc_test4/tst_chunk_hdf4.c b/nc_test4/tst_chunk_hdf4.c index 137f0d822..104e44b59 100644 --- a/nc_test4/tst_chunk_hdf4.c +++ b/nc_test4/tst_chunk_hdf4.c @@ -11,10 +11,10 @@ #include #include -#define CHUNKEDFILE "chunked.hdf4" +#define CHUNKEDFILE "ref_chunked.hdf4" #define CHUNKEDVAR "LandWater" -#define CONTIGFILE "contiguous.hdf4" +#define CONTIGFILE "ref_contiguous.hdf4" #define CONTIGVAR "pres" #define LAT_LEN 3 diff --git a/ncdump/tst_dimsizes.c b/ncdump/tst_dimsizes.c index a38bb9433..cb8fe8101 100644 --- a/ncdump/tst_dimsizes.c +++ b/ncdump/tst_dimsizes.c @@ -30,12 +30,12 @@ main(int argc, char **argv) size_t dimsize; int dimid; int stat = NC_NOERR; - + nc_set_log_level(5); printf("\n*** Testing Max Dimension Sizes\n"); printf("\n|size_t|=%lu\n",(unsigned long)sizeof(size_t)); - printf("\n*** Writing Max Dimension Size For NC_CLASSIC\n"); + printf("\n*** Writing Max Dimension Size (%d) For NC_CLASSIC\n",DIMMAXCLASSIC); if ((stat=nc_create(FILECLASSIC, NC_CLOBBER, &ncid))) ERRSTAT(stat); dimsize = DIMMAXCLASSIC; if ((stat=nc_def_dim(ncid, "testdim", dimsize, &dimid))) ERRSTAT(stat); @@ -48,10 +48,11 @@ main(int argc, char **argv) if(dimsize != DIMMAXCLASSIC) ERR; if ((stat=nc_close(ncid))) ERRSTAT(stat); - printf("\n*** Writing Max Dimension Size For NC_64BIT_OFFSET\n"); + printf("\n*** Writing Max Dimension Size (%u) For NC_64BIT_OFFSET\n",DIMMAX64OFFSET); if ((stat=nc_create(FILE64OFFSET, NC_CLOBBER | NC_64BIT_OFFSET, &ncid))) ERRSTAT(stat); dimsize = DIMMAX64OFFSET; if ((stat=nc_def_dim(ncid, "testdim", dimsize, &dimid))) ERRSTAT(stat); + if ((stat=nc_enddef(ncid))) ERRSTAT(stat); if ((stat=nc_close(ncid))) ERRSTAT(stat); printf("\n*** Reading Max Dimension Size For NC_64BIT_OFFSET\n"); @@ -62,7 +63,7 @@ main(int argc, char **argv) if ((stat=nc_close(ncid))) ERRSTAT(stat); if(sizeof(size_t) == 8) { - printf("\n*** Writing Max Dimension Size For NC_64BIT_DATA\n"); + printf("\n*** Writing Max Dimension Size (%llu) For NC_64BIT_DATA\n",DIMMAX64DATA); if ((stat=nc_create(FILE64DATA, NC_CLOBBER | NC_64BIT_DATA, &ncid))) ERRSTAT(stat); dimsize = (size_t)DIMMAX64DATA; if ((stat=nc_def_dim(ncid, "testdim", dimsize, &dimid))) ERRSTAT(stat); diff --git a/ncdump/tst_dimsizes.sh b/ncdump/tst_dimsizes.sh index 7bf0f287d..0df282874 100755 --- a/ncdump/tst_dimsizes.sh +++ b/ncdump/tst_dimsizes.sh @@ -1,6 +1,8 @@ #!/bin/sh -if test "x$srcdir" = x ; then srcdir=`pwd`; fi +#set -e + +if test "x$srcdir" = x ; then srcdir=`pwd`; fi . ../test_common.sh echo "*** Test Maximum dimension sizes X mode" @@ -48,4 +50,3 @@ fi rm -f tmp tst_dimsize_classic.nc tst_dimsize_64offset.nc tst_dimsize_64data.nc exit $RETURN - diff --git a/test_common.in b/test_common.in index 32cb09452..553b242c2 100644 --- a/test_common.in +++ b/test_common.in @@ -1,3 +1,5 @@ +set -e + TOPSRCDIR=@TOPSRCDIR@ TOPBUILDDIR=@TOPBUILDDIR@