summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ti.com>2020-09-05 10:54:18 +0300
committerTomi Valkeinen <tomi.valkeinen@ti.com>2020-09-14 11:40:34 +0300
commitccd3eb09b482d8a872b270436535c6c20ee4363f (patch)
tree0923d585f537cfac899133e7e27fc3cfbabbc8d2 /meson.build
parent5a920540b12253b1ebd7e658df19f916e3c55135 (diff)
Add meson build
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build42
1 files changed, 42 insertions, 0 deletions
diff --git a/meson.build b/meson.build
new file mode 100644
index 0000000..bc5b8bf
--- /dev/null
+++ b/meson.build
@@ -0,0 +1,42 @@
+project('kms++', 'cpp',
+ default_options : [
+ 'cpp_std=c++17',
+ ],
+)
+
+cpp = meson.get_compiler('cpp')
+cpp_arguments = []
+
+if (cpp.get_id() == 'gcc' and
+ host_machine.cpu_family() == 'arm' and
+ cpp.has_argument('-Wno-psabi'))
+ cpp_arguments += [
+ '-Wno-psabi',
+ ]
+endif
+
+if cpp.has_argument('-Wno-c99-designator')
+ cpp_arguments += [
+ '-Wno-c99-designator',
+ ]
+endif
+
+add_project_arguments(cpp_arguments, language : 'cpp')
+
+libfmt_includes = include_directories('ext/fmt/include')
+libfmt_dep = declare_dependency(include_directories : libfmt_includes,
+ compile_args : '-DFMT_HEADER_ONLY')
+
+pybind11_includes = include_directories('ext/pybind11/include')
+pybind11_dep = declare_dependency(include_directories : pybind11_includes)
+
+libdrmomap_dep = dependency('libdrm_omap', required : get_option('omap'))
+
+subdir('kms++')
+subdir('kms++util')
+subdir('utils')
+subdir('py')
+
+if get_option('kmscube')
+ subdir('kmscube')
+endif