Skip to content

Commit 7e9c69f

Browse files
committed
meson_version"
meson_version
1 parent 0dfe8d3 commit 7e9c69f

File tree

3 files changed

+41
-13
lines changed

3 files changed

+41
-13
lines changed

.editorconfig

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
root = true
2+
3+
[*]
4+
end_of_line = lf
5+
trim_trailing_whitespace = true
6+
insert_final_newline = true
7+
indent_style = space
8+
indent_size = 2
9+
10+
# Matches multiple files with brace expansion notation
11+
# Set default charset
12+
[*.{js,py}]
13+
charset = utf-8
14+
15+
[*.py]
16+
indent_style = space
17+
indent_size = 4
18+
19+
[Makefile]
20+
indent_style = tab

README.md

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,10 @@ Polymorphic API with read/write for types integer, real32, real64 with rank:
1515

1616
as well as character (string) variables and attributes.
1717

18-
Tested on systems including
18+
Tested on systems including
1919

2020
* MacOS (via homebrew)
21-
* Ubuntu 16.04/18.04 (gfortran ≥ 5.4.1) with HDF5 1.8 and 1.10
21+
* Ubuntu 16.04/18.04 (gfortran ≥ 5.4.1) with HDF5 1.8 and 1.10
2222
* Windows Subsystem for Linux.
2323

2424
Note: Currently, Cygwin does not have Fortran HDF5 libraries.
@@ -33,30 +33,38 @@ Requirements:
3333
* Linux: `apt install gfortran libhdf5-dev`
3434
* Windows: at this time,
3535
[Scoop](https://www.scivision.co/brew-install-scoop-for-windows/) and Chocolatey
36-
  do not have HDF5, possibly due to difficulties with
36+
  do not have HDF5, possibly due to difficulties with
3737
  [HDF5 and gfortran on Windows](https://stackoverflow.com/a/30056831).
3838
  Consider using
3939
[Windows Subsystem for Linux](https://www.scivision.co/install-windows-subsystem-for-linux/).
4040

4141

42-
Build this HDF5 OO Fortran interface:
42+
Build this HDF5 OO Fortran interface with other Meson or CMake.
43+
The library `libh5oo` is built, link it into your program as usual.
44+
45+
### Meson
4346

4447
```sh
45-
cd build
46-
cmake ..
48+
meson build
4749

48-
cmake --build .
50+
ninja -C build
4951

50-
ctest -V
52+
ninja test -C build
5153
```
5254

53-
The library `libh5oo` is built, link it into your program as usual.
55+
### CMake
5456

57+
```sh
58+
cd build
59+
cmake ..
5560

56-
---
61+
cmake --build .
5762

63+
ctest -V
64+
```
5865
If you need to specify a particular HDF5 library, use `cmake -DHDF5_ROOT=/path/to/hdf5lib ..`
5966

67+
6068
## Usage
6169

6270
All examples assume:
@@ -67,7 +75,7 @@ type(hdf5_file) :: h5f
6775
```
6876

6977

70-
* gzip compression may be applied for rank ≥ 2 arrays by setting `comp_lvl` to a value betwen 1 and 9.
78+
* gzip compression may be applied for rank ≥ 2 arrays by setting `comp_lvl` to a value betwen 1 and 9.
7179
Shuffle filter is automatically applied for better compression
7280
* string attributes may be applied to any variable at time of writing or later.
7381
* `chunk_size` option may be set for better compression

meson.build

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
project('Object-oriented HDF5 Fortran', 'fortran',
2-
meson_version : '0.49.999',
2+
meson_version : '>=0.50',
33
version : '1.0.0')
44

55
add_global_arguments('-g', language : 'fortran')
66

77
fc = meson.get_compiler('fortran')
88
if fc.get_id() == 'gcc'
9-
add_global_arguments( '-O', '-fimplicit-none', '-Wall', '-Wextra', '-Wpedantic', language : 'fortran')
9+
add_global_arguments( '-O', '-fimplicit-none', '-Wextra', '-Wpedantic', language : 'fortran')
1010
quiet = ['-Wno-compare-reals', '-Wno-maybe-uninitialized']
1111
else
1212
quiet = ['-w']

0 commit comments

Comments
 (0)