-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathmeson.build
More file actions
60 lines (53 loc) · 1.48 KB
/
meson.build
File metadata and controls
60 lines (53 loc) · 1.48 KB
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
# Define the project
project('milsymbol', 'cpp',
default_options: ['buildtype=debug', 'cpp_std=c++20', 'warning_level=0'],
version: '1.0.0'
)
# Source files - auto-generated with another glob file
cpp_and_c_sources = [
'src/example.cpp',
'src/Symbol.cpp',
'src/DrawCommands.cpp'
]
cpp_and_c_headers = [
'include/Types.hpp',
'include/Colors.hpp',
'include/SymbolGeometries.hpp',
'include/BBox.hpp',
'include/Symbol.hpp',
'include/DrawCommands.hpp',
'include/Schema.hpp',
'include/Constants.hpp',
'include/eternal.hpp',
'include/SymbolStyle.hpp'
]
# Gather source files
include_directories = [
'include'
]
# Create the targets
example_target = executable('milsymbol-example',
sources: [cpp_and_c_sources, cpp_and_c_headers],
include_directories: include_directories,
override_options : ['cpp_std=c++20', 'warning_level=0'],
extra_files: cpp_and_c_headers
)
# Library target
library_target = library('milsymbol',
sources: ['src/Symbol.cpp', 'src/DrawCommands.cpp'],
include_directories: include_directories,
override_options: ['cpp_std=c++20', 'warning_level=0'],
extra_files: ['include/Symbol.hpp', 'include/Types.hpp', 'include/Constants.hpp'],
install: true
)
# Headers for install
install_headers(
'include/Symbol.hpp',
'include/Types.hpp',
'include/Constants.hpp',
subdir: 'milsymbol'
)
milsymbol_cpp = declare_dependency(
link_with: library_target,
include_directories: include_directories
)