|
1 |
| -project('easyRNG', ['c', 'cpp'], version:'1.2', license: 'BSD', default_options: ['cpp_std=c++11']) |
| 1 | +project('easyRNG', ['c', 'cpp'], version:'1.2', license: 'BSD', default_options: ['cpp_std=c++11'], meson_version: '>= 0.46.0') |
2 | 2 |
|
3 | 3 | # versioning stuff -> maintain compatibility with libtool!
|
4 | 4 | # # a) If binary compatibility has been broken (eg removed or changed interfaces)
|
@@ -71,19 +71,32 @@ subdir('src')
|
71 | 71 |
|
72 | 72 | # generate pkg-config file
|
73 | 73 | pkgconfig.generate(
|
| 74 | + easyRNG_lib, |
74 | 75 | filebase: 'easyRNG',
|
75 | 76 | name: 'easyRNG',
|
76 |
| - description: 'wrapper around C++11\'s random number generators for use in C and Fortran', |
| 77 | + description: 'wrapper around C++11\'s random number generators for use in C', |
77 | 78 | version: meson.project_version(),
|
78 | 79 | libraries: easyRNG_lib,
|
79 | 80 | subdirs: 'easyRNG',
|
80 |
| - variables: ['with_fortran=' + (get_option('with-fortran') ? 'yes' : 'no')], |
81 | 81 | )
|
82 | 82 |
|
| 83 | +if get_option('with-fortran') |
| 84 | + pkgconfig.generate( |
| 85 | + easyRNGf03_lib, |
| 86 | + filebase: 'easyRNGf03', |
| 87 | + name: 'easyRNGf03', |
| 88 | + description: 'wrapper around C++11\'s random number generators for use in Fortran', |
| 89 | + version: meson.project_version(), |
| 90 | + libraries: [easyRNGf03_lib, easyRNG_lib], |
| 91 | + subdirs: 'easyRNG', |
| 92 | + ) |
| 93 | + |
| 94 | +endif |
| 95 | + |
83 | 96 | # generate RPM SPEC file
|
84 | 97 | rpm_config = configuration_data()
|
85 | 98 | rpm_config.set('VERSION', meson.project_version())
|
86 |
| -configure_file(input: 'easyRNG.spec.in', output: 'easyRNG.spec', configuration: rpm_config, install: false) |
| 99 | +configure_file(input: 'easyRNG.spec.in', output: 'easyRNG.spec', configuration: rpm_config) |
87 | 100 |
|
88 | 101 | subdir('tests')
|
89 | 102 |
|
|
0 commit comments