aboutsummaryrefslogtreecommitdiff
path: root/contrib/DirectX-Headers/meson.build
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/DirectX-Headers/meson.build')
-rw-r--r--contrib/DirectX-Headers/meson.build35
1 files changed, 35 insertions, 0 deletions
diff --git a/contrib/DirectX-Headers/meson.build b/contrib/DirectX-Headers/meson.build
new file mode 100644
index 0000000..3174221
--- /dev/null
+++ b/contrib/DirectX-Headers/meson.build
@@ -0,0 +1,35 @@
1# Copyright (c) Microsoft Corporation.
2# Licensed under the MIT License.
3
4project('DirectX-Headers', 'cpp', version : '1.4.9',
5 default_options : ['cpp_std=c++14'])
6
7inc_dirs = [include_directories('include', is_system : true)]
8install_inc_subdirs = ['']
9
10if host_machine.system() != 'windows'
11 inc_dirs += include_directories('include/wsl/stubs', is_system : true)
12 install_inc_subdirs += ['', 'wsl/stubs', 'directx']
13endif
14
15guids_lib = static_library('DirectX-Guids', 'src/dxguids.cpp', include_directories : inc_dirs, install : true)
16
17dep_dxheaders = declare_dependency(
18 link_with : guids_lib,
19 include_directories : inc_dirs)
20
21if meson.version().version_compare('>=0.54.0')
22 meson.override_dependency('DirectX-Headers', dep_dxheaders)
23endif
24
25if not meson.is_subproject() and get_option('build-test')
26 subdir('test')
27endif
28
29pkg = import('pkgconfig')
30pkg.generate(name : 'DirectX-Headers',
31 description : 'Headers for using D3D12',
32 libraries : [guids_lib],
33 version : meson.project_version(),
34 subdirs : install_inc_subdirs)
35install_subdir('include', install_dir : '')