-
Notifications
You must be signed in to change notification settings - Fork 0
/
meson.build
54 lines (51 loc) · 906 Bytes
/
meson.build
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
project(
'mpi-stubs',
'c',
version: '4.2',
license: 'MIT',
meson_version: '>=1.0.0',
)
fs = import('fs')
prefix = get_option('prefix')
bindir = get_option('bindir')
includedir = get_option('includedir')
libdir = get_option('libdir')
prog_dirs = {
'includedir':
fs.is_absolute(includedir) ?
includedir : prefix / includedir,
'libdir':
fs.is_absolute(libdir) ?
libdir : prefix / libdir,
}
prog_vars = {
'mpicc': {
'CC': 'CC',
'cc': 'cc',
'op': 'cc',
},
'mpicxx': {
'CC': 'CXX',
'cc': 'c++',
'op': 'cxx',
},
}
foreach prog: ['mpicc', 'mpicxx']
configure_file(
input: 'mpicc.in',
configuration: prog_dirs + prog_vars[prog],
output: prog,
install: true,
install_dir: bindir,
install_mode: 'rwxr-xr-x',
)
endforeach
install_headers(
'mpi.h'
)
library(
'mpi_abi',
'mpistubs.c',
version: '0',
install : true,
)