aboutsummaryrefslogtreecommitdiff
path: root/test cases
diff options
context:
space:
mode:
authorMichael Hirsch, Ph.D <scivision@users.noreply.github.com>2019-11-10 10:14:01 -0500
committerJussi Pakkanen <jpakkane@gmail.com>2019-11-28 12:51:58 +0200
commitc02593fddc70402d8a3f50b8ae476e1778d5cd3c (patch)
treeec6106c602800cb3f771b03074ba570c82f13b8a /test cases
parentdd15c47ea8c8cde4b954dad1ea9625c360412f14 (diff)
downloadmeson-c02593fddc70402d8a3f50b8ae476e1778d5cd3c.zip
meson-c02593fddc70402d8a3f50b8ae476e1778d5cd3c.tar.gz
meson-c02593fddc70402d8a3f50b8ae476e1778d5cd3c.tar.bz2
HDF5: make much more robust across platforms
This addresses various real-world problems with HDF5 pkg-config, including * hdf*.pc with package versions as part of the filename * malformed hdf*.pc missing the commonly-used HDF5 HL module --- Additionally, this refactors more complicated dependencies such as HDF5 and OpenMPI. This may help us deduplicate internal dependency code in the future. HDF5 selftest: improve platform-agnostic test ci: init demo github action for HDF5 framework ci Actions: hold off on MSYS2 for now [skip ci] hdf5: ensure C libraries always included ci: mac hdf5--use clang+gfortran
Diffstat (limited to 'test cases')
-rw-r--r--test cases/frameworks/25 hdf5/meson.build35
1 files changed, 11 insertions, 24 deletions
diff --git a/test cases/frameworks/25 hdf5/meson.build b/test cases/frameworks/25 hdf5/meson.build
index 9033354..20bc5cd 100644
--- a/test cases/frameworks/25 hdf5/meson.build
+++ b/test cases/frameworks/25 hdf5/meson.build
@@ -1,40 +1,27 @@
-project('hdf5_test', 'c', 'cpp')
-
-if build_machine.system() == 'darwin'
- error('MESON_SKIP_TEST: HDF5 CI image not setup for OSX.')
-endif
-
-if build_machine.system() == 'cygwin'
- error('MESON_SKIP_TEST: HDF5 CI image not setup for Cygwin.')
-endif
+project('hdf5_framework', 'c')
+# NOTE: all HDF5 languages must have HDF5 C library working.
# --- C tests
h5c = dependency('hdf5', language : 'c', required : false)
if not h5c.found()
- error('MESON_SKIP_TEST: HDF5 C library not found, skipping HDF5 framework tests.')
+ error('MESON_SKIP_TEST: HDF5 C library not found.')
endif
exec = executable('exec', 'main.c', dependencies : h5c)
-
-test('HDF5 C', exec)
+test('HDF5 C', exec, timeout: 30)
# --- C++ tests
-h5cpp = dependency('hdf5', language : 'cpp', required : false)
-if h5cpp.found()
+if add_languages('cpp')
+ h5cpp = dependency('hdf5', language : 'cpp', required : false, disabler: true)
execpp = executable('execpp', 'main.cpp', dependencies : h5cpp)
- test('HDF5 C++', execpp)
+ test('HDF5 C++', execpp, timeout: 30)
endif
# --- Fortran tests
-if build_machine.system() != 'windows'
- add_languages('fortran')
-
- h5f = dependency('hdf5', language : 'fortran', required : false)
- if h5f.found()
- exef = executable('exef', 'main.f90', dependencies : h5f)
-
- test('HDF5 Fortran', exef)
- endif
+if add_languages('fortran')
+ h5f = dependency('hdf5', language : 'fortran', required : false, disabler: true)
+ exef = executable('exef', 'main.f90', dependencies : h5f)
+ test('HDF5 Fortran', exef, timeout: 30)
endif
# Check we can apply a version constraint