forked from gentoo-utils/gentoo-utils
31 lines
662 B
Meson
31 lines
662 B
Meson
project(
|
|
'gentoo-utils',
|
|
['rust', 'cpp'],
|
|
meson_version: '>=1.9.1',
|
|
default_options: {'rust_std': '2024', 'rust_nightly': 'enabled'},
|
|
)
|
|
|
|
rust = import('rust')
|
|
fs = import('fs')
|
|
|
|
mon = dependency('mon-0.1-rs')
|
|
get = dependency('get-0.1-rs')
|
|
itertools = dependency('itertools-0.14-rs')
|
|
thiserror = subproject('thiserror').get_variable('thiserror')
|
|
|
|
gentoo_utils = static_library(
|
|
'gentoo_utils',
|
|
'src/lib.rs',
|
|
dependencies: [mon, get, itertools],
|
|
link_with: [thiserror],
|
|
)
|
|
|
|
if get_option('tests').enabled()
|
|
rust.test('unittests', gentoo_utils)
|
|
subdir('tests')
|
|
endif
|
|
|
|
if get_option('fuzz').enabled()
|
|
subdir('fuzz')
|
|
endif
|