-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmeson.build
57 lines (48 loc) · 1.22 KB
/
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
55
56
57
# SPDX-License-Identifier: LGPL-2.1
#
# Copyright (c) 2023 Daniel Wagner, SUSE LLC
project(
'libtraceevent', ['c'],
meson_version: '>= 0.58.0',
license: 'LGPL-2.1',
version: '1.8.2',
default_options: [
'c_std=gnu99',
'buildtype=debug',
'default_library=both',
'prefix=/usr/local',
'warning_level=1',
])
library_version = meson.project_version()
cunit_dep = dependency('cunit', required : false)
prefixdir = get_option('prefix')
mandir = join_paths(prefixdir, get_option('mandir'))
htmldir = join_paths(prefixdir, get_option('htmldir'))
libdir = join_paths(prefixdir, get_option('libdir'))
plugindir = get_option('plugindir')
if plugindir == ''
plugindir = join_paths(libdir, 'libtraceevent/plugins')
endif
add_project_arguments(
[
'-D_GNU_SOURCE',
'-DPLUGIN_DIR="@0@"'.format(plugindir),
],
language : 'c',
)
incdir = include_directories(['include', 'include/traceevent'])
subdir('src')
subdir('include/traceevent')
subdir('plugins')
if cunit_dep.found()
subdir('utest')
endif
subdir('samples')
if get_option('doc')
subdir('Documentation')
custom_target(
'docs',
output: 'docs',
depends: [html, man],
command: ['echo'])
endif