This repository has been archived by the owner on Jun 22, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
meson.build
76 lines (64 loc) · 3.11 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
project('codectrl-cxx-logger', 'cpp',
version: '0.2.0',
license: 'MIT',
meson_version: '>= 0.55.0',
default_options: [
'cpp_std=c++17',
'default_library=both',
]
)
emails = ['<[email protected]>', '<[email protected]>']
description = 'The codeCTRL logger library for C++'
codectrl_logger_includes = [include_directories('include')]
libbacktrace_dep = dependency('libbacktrace', required: false)
thread_dep = dependency('threads', required: false)
asio_proj = subproject('asio')
boost_array_proj = subproject('boost_array')
boost_assert_proj = subproject('boost_assert')
boost_config_proj = subproject('boost_config')
boost_container_hash_proj = subproject('boost_container_hash')
boost_core_proj = subproject('boost_core')
boost_detail_proj = subproject('boost_detail')
boost_integer_proj = subproject('boost_integer')
boost_predef_proj = subproject('boost_predef')
boost_stacktrace_proj = subproject('boost_stacktrace')
boost_static_assert_proj = subproject('boost_static_assert')
boost_throw_exception_proj = subproject('boost_throw_exception')
boost_type_index_proj = subproject('boost_type_index')
boost_type_traits_proj = subproject('boost_type_traits')
jsoncons_proj = subproject('jsoncons')
codectrl_logger_includes += [
asio_proj.get_variable('asio_includes'),
boost_array_proj.get_variable('boost_array_includes'),
boost_assert_proj.get_variable('boost_assert_includes'),
boost_config_proj.get_variable('boost_config_includes'),
boost_container_hash_proj.get_variable('boost_container_hash_includes'),
boost_core_proj.get_variable('boost_core_includes'),
boost_detail_proj.get_variable('boost_detail_includes'),
boost_integer_proj.get_variable('boost_integer_includes'),
boost_predef_proj.get_variable('boost_predef_includes'),
boost_stacktrace_proj.get_variable('boost_stacktrace_includes'),
boost_static_assert_proj.get_variable('boost_static_assert_includes'),
boost_throw_exception_proj.get_variable('boost_throw_exception_includes'),
boost_type_index_proj.get_variable('boost_type_index_includes'),
boost_type_traits_proj.get_variable('boost_type_traits_includes'),
jsoncons_proj.get_variable('jsoncons_includes')
]
if get_option('buildtype') == 'debug' and build_machine.system() != 'windows'
add_project_arguments('-DDEBUG', '-DBOOST_STACKTRACE_USE_BACKTRACE', language: 'cpp')
elif get_option('buildtype') == 'debug'
add_project_arguments('-DDEBUG', '-DBOOST_STACKTRACE_USE_WINDBG', language: 'cpp')
endif
dependencies = []
if build_machine.system() != 'windows'
if not libbacktrace_dep.found()
libbacktrace_proj = subproject('libbacktrace')
libbacktrace_dep = libbacktrace_proj.get_variable('libbacktrace_dep')
codectrl_logger_includes += libbacktrace_proj.get_variable('libbacktrace_includes')
endif
dependencies = [libbacktrace_dep, thread_dep]
endif
include = codectrl_logger_includes
subdir('include')
subdir('tests')
codectrl_dep = declare_dependency(dependencies: dependencies)