Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop' into pause_errors_12
Browse files Browse the repository at this point in the history
  • Loading branch information
qkoziol committed Oct 2, 2024
2 parents 95f1b59 + 2921f27 commit 956a237
Show file tree
Hide file tree
Showing 117 changed files with 3,589 additions and 3,939 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/hdfeos5.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: hdfeos5 dev

# Triggers the workflow on push or pull request or on demand
on:
workflow_dispatch:
push:
pull_request:
branches: [ develop ]
paths-ignore:
- '.github/CODEOWNERS'
- '.github/FUNDING.yml'
- 'doc/**'
- 'release_docs/**'
- 'ACKNOWLEDGEMENTS'
- 'COPYING**'
- '**.md'

# Using concurrency to cancel any in-progress job or run
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref && github.ref || github.run_id }}
cancel-in-progress: true

permissions:
contents: read

jobs:
build:
name: Build hdfeos5
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]

- name: Install Autotools Dependencies (Linux)
run: |
sudo apt update
sudo apt install automake autoconf libtool libtool-bin
- name: Install HDF5
run: |
./autogen.sh
./configure --prefix=/usr/local --disable-tests --with-default-api-version=v16
make
sudo make install
- name: Install HDF-EOS5
run: |
wget -O HDF-EOS5.2.0.tar.gz "https://git.earthdata.nasa.gov/projects/DAS/repos/hdfeos5/raw/hdf-eos5-2.0-src.tar.gz?at=refs%2Fheads%2FHDFEOS5_2.0"
tar zxvf HDF-EOS5.2.0.tar.gz
cd hdf-eos5-2.0
./configure CC=/usr/local/bin/h5cc --prefix=/usr/local/ --enable-install-include
make
make check
sudo make install
5 changes: 5 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ set (HDF5_LIB_BASE "hdf5")

set (HDF5_LIB_CORE "")
set (HDF5_TEST_LIB_CORE "_test")
set (HDF5_TEST_PAR_LIB_CORE "_testpar")
set (HDF5_CPP_LIB_CORE "_cpp")
set (HDF5_HL_LIB_CORE "_hl")
set (HDF5_HL_CPP_LIB_CORE "_hl_cpp")
Expand All @@ -174,6 +175,7 @@ set (HDF5_JAVA_JNI_LIB_CORE "_java")

set (HDF5_LIB_CORENAME "${HDF5_LIB_BASE}")
set (HDF5_TEST_LIB_CORENAME "${HDF5_LIB_BASE}${HDF5_TEST_LIB_CORE}")
set (HDF5_TEST_PAR_LIB_CORENAME "${HDF5_LIB_BASE}${HDF5_TEST_PAR_LIB_CORE}")
set (HDF5_CPP_LIB_CORENAME "${HDF5_LIB_BASE}${HDF5_CPP_LIB_CORE}")
set (HDF5_HL_LIB_CORENAME "${HDF5_LIB_BASE}${HDF5_HL_LIB_CORE}")
set (HDF5_HL_CPP_LIB_CORENAME "${HDF5_LIB_BASE}${HDF5_HL_CPP_LIB_CORE}")
Expand All @@ -194,6 +196,7 @@ set (HDF5_JAVA_TEST_LIB_CORENAME "jartest5")
#-----------------------------------------------------------------------------
set (HDF5_LIB_NAME "${HDF5_EXTERNAL_LIB_PREFIX}${HDF5_LIB_BASE}${HDF5_LIB_INFIX}${HDF5_LIB_CORE}${HDF5_EXTERNAL_LIB_SUFFIX}")
set (HDF5_TEST_LIB_NAME "${HDF5_EXTERNAL_LIB_PREFIX}${HDF5_LIB_BASE}${HDF5_LIB_INFIX}${HDF5_TEST_LIB_CORE}${HDF5_EXTERNAL_LIB_SUFFIX}")
set (HDF5_TEST_PAR_LIB_NAME "${HDF5_EXTERNAL_LIB_PREFIX}${HDF5_LIB_BASE}${HDF5_LIB_INFIX}${HDF5_TEST_PAR_LIB_CORE}${HDF5_EXTERNAL_LIB_SUFFIX}")
set (HDF5_CPP_LIB_NAME "${HDF5_EXTERNAL_LIB_PREFIX}${HDF5_LIB_BASE}${HDF5_LIB_INFIX}${HDF5_CPP_LIB_CORE}${HDF5_EXTERNAL_LIB_SUFFIX}")
set (HDF5_HL_LIB_NAME "${HDF5_EXTERNAL_LIB_PREFIX}${HDF5_LIB_BASE}${HDF5_LIB_INFIX}${HDF5_HL_LIB_CORE}${HDF5_EXTERNAL_LIB_SUFFIX}")
set (HDF5_HL_CPP_LIB_NAME "${HDF5_EXTERNAL_LIB_PREFIX}${HDF5_LIB_BASE}${HDF5_LIB_INFIX}${HDF5_HL_CPP_LIB_CORE}${HDF5_EXTERNAL_LIB_SUFFIX}")
Expand All @@ -216,6 +219,7 @@ set (HDF5_JAVA_TEST_LIB_NAME "${HDF5_EXTERNAL_LIB_PREFIX}${HDF5_JAVA_TEST_LIB
#-----------------------------------------------------------------------------
set (HDF5_LIB_TARGET "${HDF5_LIB_CORENAME}-static")
set (HDF5_TEST_LIB_TARGET "${HDF5_TEST_LIB_CORENAME}-static")
set (HDF5_TEST_PAR_LIB_TARGET "${HDF5_TEST_PAR_LIB_CORENAME}-static")
set (HDF5_CPP_LIB_TARGET "${HDF5_CPP_LIB_CORENAME}-static")
set (HDF5_HL_LIB_TARGET "${HDF5_HL_LIB_CORENAME}-static")
set (HDF5_HL_CPP_LIB_TARGET "${HDF5_HL_CPP_LIB_CORENAME}-static")
Expand All @@ -232,6 +236,7 @@ set (HDF5_JAVA_HDF5_LIB_TARGET "${HDF5_JAVA_HDF5_LIB_CORENAME}")
set (HDF5_JAVA_TEST_LIB_TARGET "${HDF5_JAVA_TEST_LIB_CORENAME}")
set (HDF5_LIBSH_TARGET "${HDF5_LIB_CORENAME}-shared")
set (HDF5_TEST_LIBSH_TARGET "${HDF5_TEST_LIB_CORENAME}-shared")
set (HDF5_TEST_PAR_LIBSH_TARGET "${HDF5_TEST_PAR_LIB_CORENAME}-shared")
set (HDF5_CPP_LIBSH_TARGET "${HDF5_CPP_LIB_CORENAME}-shared")
set (HDF5_HL_LIBSH_TARGET "${HDF5_HL_LIB_CORENAME}-shared")
set (HDF5_HL_CPP_LIBSH_TARGET "${HDF5_HL_CPP_LIB_CORENAME}-shared")
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ HDF5 version 1.15.0 currently under development

[![develop cmake build status](https://img.shields.io/github/actions/workflow/status/HDFGroup/hdf5/cmake.yml?branch=develop&label=HDF5%20develop%20CMake%20CI)](https://github.com/HDFGroup/hdf5/actions/workflows/cmake.yml?query=branch%3Adevelop)
[![develop autotools build status](https://img.shields.io/github/actions/workflow/status/HDFGroup/hdf5/autotools.yml?branch=develop&label=HDF5%20develop%20Autotools%20CI)](https://github.com/HDFGroup/hdf5/actions/workflows/autotools.yml?query=branch%3Adevelop)
[![HDF-EOS5 build status](https://img.shields.io/github/actions/workflow/status/HDFGroup/hdf5/hdfeos5.yml?branch=develop&label=HDF-EOS5)](https://github.com/HDFGroup/hdf5/actions/workflows/hdfeos5.yml?query=branch%3Adevelop)
[![netCDF build status](https://img.shields.io/github/actions/workflow/status/HDFGroup/hdf5/netcdf.yml?branch=develop&label=netCDF)](https://github.com/HDFGroup/hdf5/actions/workflows/netcdf.yml?query=branch%3Adevelop)
[![h5py build status](https://img.shields.io/github/actions/workflow/status/HDFGroup/hdf5/h5py.yml?branch=develop&label=h5py)](https://github.com/HDFGroup/hdf5/actions/workflows/h5py.yml?query=branch%3Adevelop)
[![CVE regression](https://img.shields.io/github/actions/workflow/status/HDFGroup/hdf5/cve.yml?branch=develop&label=CVE)](https://github.com/HDFGroup/hdf5/actions/workflows/cve.yml?query=branch%3Adevelop)
Expand Down
13 changes: 6 additions & 7 deletions c++/test/dsets.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1451,7 +1451,7 @@ test_read_string(H5File &file)
*-------------------------------------------------------------------------
*/
extern "C" void
test_dset()
test_dset(const void *params)
{
hid_t fapl_id;
fapl_id = h5_fileaccess(); // in h5test.c, returns a file access template
Expand Down Expand Up @@ -1492,9 +1492,6 @@ test_dset()
catch (Exception &E) {
test_report(nerrors, H5std_string(" Dataset"));
}

// Clean up data file
cleanup_dsets();
} // test_dset

/*-------------------------------------------------------------------------
Expand All @@ -1506,8 +1503,10 @@ test_dset()
*-------------------------------------------------------------------------
*/
extern "C" void
cleanup_dsets()
cleanup_dsets(void *params)
{
HDremove(FILE1.c_str());
HDremove(FILE_ACCPLIST.c_str());
if (GetTestCleanup()) {
HDremove(FILE1.c_str());
HDremove(FILE_ACCPLIST.c_str());
}
} // cleanup_dsets
61 changes: 31 additions & 30 deletions c++/test/h5cpputil.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,16 @@
#define H5cpputil_H

#include "h5test.h"
#include "testframe.h"

using namespace H5;
using std::cerr;
using std::endl;

#define MESSAGE(V, A) \
do { \
if (HDGetTestVerbosity() > (V)) \
print_func A; \
if (GetTestVerbosity() > (V)) \
printf A; \
} while (0)
#define SUBTEST(TEST) \
do { \
Expand Down Expand Up @@ -142,36 +143,36 @@ verify_val(Type1 x, Type2 value, float epsilon, const char *msg, int line, const
#ifdef __cplusplus
extern "C" {
#endif
void test_array();
void test_attr();
void test_compound();
void test_dsproplist();
void test_file();
void test_filters();
void test_links();
void test_h5s();
void test_iterate();
void test_object();
void test_reference();
void test_types();
void test_vlstrings();
void test_dset();
void test_array(const void *params);
void test_attr(const void *params);
void test_compound(const void *params);
void test_dsproplist(const void *params);
void test_file(const void *params);
void test_filters(const void *params);
void test_links(const void *params);
void test_h5s(const void *params);
void test_iterate(const void *params);
void test_object(const void *params);
void test_reference(const void *params);
void test_types(const void *params);
void test_vlstrings(const void *params);
void test_dset(const void *params);

/* Prototypes for the cleanup routines */
void cleanup_array();
void cleanup_attr();
void cleanup_compound();
void cleanup_dsproplist();
void cleanup_dsets();
void cleanup_file();
void cleanup_filters();
void cleanup_h5s();
void cleanup_iterate();
void cleanup_links();
void cleanup_object();
void cleanup_reference();
void cleanup_types();
void cleanup_vlstrings();
void cleanup_array(void *params);
void cleanup_attr(void *params);
void cleanup_compound(void *params);
void cleanup_dsproplist(void *params);
void cleanup_dsets(void *params);
void cleanup_file(void *params);
void cleanup_filters(void *params);
void cleanup_h5s(void *params);
void cleanup_iterate(void *params);
void cleanup_links(void *params);
void cleanup_object(void *params);
void cleanup_reference(void *params);
void cleanup_types(void *params);
void cleanup_vlstrings(void *params);

#ifdef __cplusplus
}
Expand Down
8 changes: 5 additions & 3 deletions c++/test/tarray.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ test_array_info()
*-------------------------------------------------------------------------
*/
extern "C" void
test_array()
test_array(const void *params)
{
// Output message about test being performed
MESSAGE(5, ("Testing Array Datatypes\n"));
Expand All @@ -502,7 +502,9 @@ test_array()
*-------------------------------------------------------------------------
*/
extern "C" void
cleanup_array()
cleanup_array(void *params)
{
HDremove(FILENAME.c_str());
if (GetTestCleanup()) {
HDremove(FILENAME.c_str());
}
} // cleanup_array
18 changes: 10 additions & 8 deletions c++/test/tattr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1956,7 +1956,7 @@ test_attr_corder_create_basic(FileCreatPropList &fcpl, FileAccPropList &fapl)
*-------------------------------------------------------------------------
*/
extern "C" void
test_attr()
test_attr(const void *params)
{
// Output message about test being performed
MESSAGE(5, ("Testing Attributes\n"));
Expand Down Expand Up @@ -2041,12 +2041,14 @@ test_attr()
*-------------------------------------------------------------------------
*/
extern "C" void
cleanup_attr()
cleanup_attr(void *params)
{
HDremove(FILE_BASIC.c_str());
HDremove(FILE_COMPOUND.c_str());
HDremove(FILE_SCALAR.c_str());
HDremove(FILE_MULTI.c_str());
HDremove(FILE_DTYPE.c_str());
HDremove(FILE_CRTPROPS.c_str());
if (GetTestCleanup()) {
HDremove(FILE_BASIC.c_str());
HDremove(FILE_COMPOUND.c_str());
HDremove(FILE_SCALAR.c_str());
HDremove(FILE_MULTI.c_str());
HDremove(FILE_DTYPE.c_str());
HDremove(FILE_CRTPROPS.c_str());
}
}
8 changes: 5 additions & 3 deletions c++/test/tcompound.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -729,7 +729,7 @@ test_compound_set_size()
*-------------------------------------------------------------------------
*/
extern "C" void
test_compound()
test_compound(const void *params)
{
// Output message about test being performed
MESSAGE(5, ("Testing Compound Data Type operations\n"));
Expand All @@ -753,7 +753,9 @@ test_compound()
*-------------------------------------------------------------------------
*/
extern "C" void
cleanup_compound()
cleanup_compound(void *params)
{
HDremove(COMPFILE.c_str());
if (GetTestCleanup()) {
HDremove(COMPFILE.c_str());
}
} // cleanup_file
8 changes: 5 additions & 3 deletions c++/test/tdspl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ test_transfplist()
*-------------------------------------------------------------------------
*/
extern "C" void
test_dsproplist()
test_dsproplist(const void *params)
{
// Output message about test being performed
MESSAGE(5, ("Testing Generic Dataset Property Lists\n"));
Expand All @@ -132,7 +132,9 @@ test_dsproplist()
*-------------------------------------------------------------------------
*/
extern "C" void
cleanup_dsproplist()
cleanup_dsproplist(void *params)
{
HDremove(FILENAME.c_str());
if (GetTestCleanup()) {
HDremove(FILENAME.c_str());
}
}
46 changes: 23 additions & 23 deletions c++/test/testhdf5.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,50 +57,50 @@ main(int argc, char *argv[])
// caused deliberately and expected.
Exception::dontPrint();
/* Initialize testing framework */
TestInit(argv[0], NULL, NULL);
TestInit(argv[0], NULL, NULL, 0);

// testing file creation and opening in tfile.cpp
AddTest("tfile", test_file, cleanup_file, "File I/O Operations", NULL);
AddTest("tfile", test_file, NULL, cleanup_file, NULL, 0, "File I/O Operations");
// testing dataset functionalities in dset.cpp
AddTest("dsets", test_dset, cleanup_dsets, "Dataset I/O Operations", NULL);
AddTest("dsets", test_dset, NULL, cleanup_dsets, NULL, 0, "Dataset I/O Operations");
// testing dataspace functionalities in th5s.cpp
AddTest("th5s", test_h5s, cleanup_h5s, "Dataspaces", NULL);
AddTest("th5s", test_h5s, NULL, cleanup_h5s, NULL, 0, "Dataspaces");
// testing attribute functionalities in tattr.cpp
AddTest("tattr", test_attr, cleanup_attr, "Attributes", NULL);
AddTest("tattr", test_attr, NULL, cleanup_attr, NULL, 0, "Attributes");
// testing object functionalities in tobject.cpp
AddTest("tobject", test_object, cleanup_object, "Objects", NULL);
AddTest("tobject", test_object, NULL, cleanup_object, NULL, 0, "Objects");
// testing reference functionalities in trefer.cpp
AddTest("trefer", test_reference, cleanup_reference, "References", NULL);
AddTest("trefer", test_reference, NULL, cleanup_reference, NULL, 0, "References");
// testing variable-length strings in tvlstr.cpp
AddTest("tvlstr", test_vlstrings, cleanup_vlstrings, "Variable-Length Strings", NULL);
AddTest("ttypes", test_types, cleanup_types, "Generic Data Types", NULL);
AddTest("tarray", test_array, cleanup_array, "Array Datatypes", NULL);
AddTest("tcompound", test_compound, cleanup_compound, "Compound Data Types", NULL);
AddTest("tdspl", test_dsproplist, cleanup_dsproplist, "Dataset Property List", NULL);
AddTest("tfilter", test_filters, cleanup_filters, "Various Filters", NULL);
AddTest("tlinks", test_links, cleanup_links, "Various Links", NULL);
AddTest("tvlstr", test_vlstrings, NULL, cleanup_vlstrings, NULL, 0, "Variable-Length Strings");
AddTest("ttypes", test_types, NULL, cleanup_types, NULL, 0, "Generic Data Types");
AddTest("tarray", test_array, NULL, cleanup_array, NULL, 0, "Array Datatypes");
AddTest("tcompound", test_compound, NULL, cleanup_compound, NULL, 0, "Compound Data Types");
AddTest("tdspl", test_dsproplist, NULL, cleanup_dsproplist, NULL, 0, "Dataset Property List");
AddTest("tfilter", test_filters, NULL, cleanup_filters, NULL, 0, "Various Filters");
AddTest("tlinks", test_links, NULL, cleanup_links, NULL, 0, "Various Links");
/* Comment out tests that are not done yet. - BMR, Feb 2001
AddTest("select", test_select, cleanup_select, "Selections", NULL);
AddTest("time", test_time, cleanup_time, "Time Datatypes", NULL);
AddTest("vltypes", test_vltypes, cleanup_vltypes, "Variable-Length Datatypes", NULL);
AddTest("select", test_select, NULL, cleanup_select, NULL, 0, "Selections");
AddTest("time", test_time, NULL, cleanup_time, NULL, 0, "Time Datatypes");
AddTest("vltypes", test_vltypes, NULL, cleanup_vltypes, NULL, 0, "Variable-Length Datatypes");
*/
AddTest("iterate", test_iterate, cleanup_iterate, "Group & Attribute Iteration", NULL);
AddTest("iterate", test_iterate, NULL, cleanup_iterate, NULL, 0, "Group & Attribute Iteration");
/*
AddTest("genprop", test_genprop, cleanup_genprop, "Generic Properties", NULL);
AddTest("id", test_ids, NULL, "User-Created Identifiers", NULL);
AddTest("genprop", test_genprop, NULL, cleanup_genprop, NULL, 0, "Generic Properties");
AddTest("id", test_ids, NULL, NULL, NULL, 0, "User-Created Identifiers");
Comment out tests that are not done yet */

/* Tentative - BMR 2007/1/12
AddTest("enum", test_enum, cleanup_enum, "Enum Data Types", NULL);
AddTest("enum", test_enum, NULL, cleanup_enum, NULL, 0, "Enum Data Types");
*/
}
catch (Exception &E) {
issue_fail_msg("Tests failed", __LINE__, __FILE__, E.getCDetailMsg());
}

/* Display testing information */
TestInfo(argv[0]);
TestInfo(stdout);

/* Parse command line arguments */
TestParseCmdLine(argc, argv);
Expand All @@ -110,7 +110,7 @@ main(int argc, char *argv[])

/* Display test summary, if requested */
if (GetTestSummary())
TestSummary();
TestSummary(stdout);

/* Clean up test files, if allowed */
if (GetTestCleanup() && !getenv(HDF5_NOCLEANUP))
Expand Down
Loading

0 comments on commit 956a237

Please sign in to comment.