diff options
| author | Scott Anderson <scott@anderso.nz> | 2019-12-17 22:08:02 +1300 |
|---|---|---|
| committer | Eric Engestrom <eric@engestrom.ch> | 2019-12-17 23:07:53 +0000 |
| commit | c70bd7b7059b2df0d73b5dfbad19f841957bcdba (patch) | |
| tree | c586bf792a135512000d3cb5d98e9f50f72c35a1 | |
| parent | edafcf18e5b5347c1f5dc5a2d9f87da1a00789b9 (diff) | |
| download | external_libdrm-c70bd7b7059b2df0d73b5dfbad19f841957bcdba.tar.gz external_libdrm-c70bd7b7059b2df0d73b5dfbad19f841957bcdba.tar.bz2 external_libdrm-c70bd7b7059b2df0d73b5dfbad19f841957bcdba.zip | |
meson: Replace 'config.h' with config_file
This fixes an issue with libdrm failing to build when used as a meson
subproject. Using 'config.h' directly will cause it to possibly refer to
the wrong file.
By using `@0@.format(config_file)`, it will be transformed into the
correct relative path, e.g. `./config.h` in normal build,
`./subprojects/libdrm/config.h` in subproject build.
Signed-off-by: Scott Anderson <scott@anderso.nz>
Acked-by: Eric Engestrom <eric.engestrom@intel.com>
| -rw-r--r-- | meson.build | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/meson.build b/meson.build index 96ee50c5..782b1a39 100644 --- a/meson.build +++ b/meson.build @@ -285,7 +285,7 @@ config_file = configure_file( configuration : config, output : 'config.h', ) -add_project_arguments('-include', 'config.h', language : 'c') +add_project_arguments('-include', '@0@'.format(config_file), language : 'c') inc_root = include_directories('.') inc_drm = include_directories('include/drm') |
