Skip to content

Commit 7ce4d9c

Browse files
committed
meson: move assert hdf5.found() after link test
1 parent b194f43 commit 7ce4d9c

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

meson/meson.build

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,11 @@ quiet = fc.get_supported_arguments(['-w', '-Wno-compare-reals', '-Wno-maybe-unin
1212
# NOTE: static: parameter is too strict for now. Works more reliably without this parameter
1313

1414
hdf5 = dependency('hdf5', language : 'fortran', required: false, disabler: true) # , static: use_static
15-
if not meson.is_subproject()
16-
assert(hdf5.found(), 'hdf5 library is required for h5fortran')
17-
endif
1815

1916
if not fc.links(files('../src/tests/test_minimal.f90'), dependencies: hdf5, name: 'HDF5')
2017
hdf5 = disabler()
2118
endif
19+
20+
if not meson.is_subproject()
21+
assert(hdf5.found(), 'hdf5 library is required for h5fortran')
22+
endif

0 commit comments

Comments
 (0)