diff options
author | Patrick Griffis <tingping@tingping.se> | 2016-10-02 05:07:35 -0400 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2016-10-02 12:16:22 -0400 |
commit | 084b854ce057ee6d954c24e58321caa92f542bc5 (patch) | |
tree | c8090c0de908c00ac1a71558bf7099977d62b8b5 | |
parent | c69c15ee16262908c7653a8de0436ce4463df6dd (diff) | |
download | meson-084b854ce057ee6d954c24e58321caa92f542bc5.zip meson-084b854ce057ee6d954c24e58321caa92f542bc5.tar.gz meson-084b854ce057ee6d954c24e58321caa92f542bc5.tar.bz2 |
gnome: Consistently include current source dir
This is a common pattern so avoid the duplication
-rw-r--r-- | mesonbuild/modules/gnome.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py index 11abf88..4cd0505 100644 --- a/mesonbuild/modules/gnome.py +++ b/mesonbuild/modules/gnome.py @@ -45,6 +45,9 @@ class GnomeModule: if not isinstance(source_dirs, list): source_dirs = [source_dirs] + # Always include current directory, but after paths set by user + source_dirs.append(os.path.join(state.environment.get_source_dir(), state.subdir)) + if len(args) < 2: raise MesonException('Not enough arguments; The name of the resource and the path to the XML file are required') @@ -220,6 +223,7 @@ class GnomeModule: extra_args = mesonlib.stringlistify(kwargs.pop('extra_args', [])) scan_command += extra_args + scan_command += ['-I' + os.path.join(state.environment.get_source_dir(), state.subdir)] scan_command += self.get_include_args(state, girtarget.get_include_dirs()) if 'link_with' in kwargs: |