diff options
author | Jon Turney <jon.turney@dronecode.org.uk> | 2018-06-04 13:45:13 +0100 |
---|---|---|
committer | Nirbheek Chauhan <nirbheek.chauhan@gmail.com> | 2018-06-18 10:52:21 +0000 |
commit | c0f59399e43bb83de4cf78e80034326ef381d9ac (patch) | |
tree | d057bd08f399e75156b4ea97530dae3a0883b5fe /mesonbuild/modules/windows.py | |
parent | c9a89027accff8385028a2b5e93465d28c63be36 (diff) | |
download | meson-c0f59399e43bb83de4cf78e80034326ef381d9ac.zip meson-c0f59399e43bb83de4cf78e80034326ef381d9ac.tar.gz meson-c0f59399e43bb83de4cf78e80034326ef381d9ac.tar.bz2 |
Add a depends: keyword to windows.compile_resources()
Expose depends: from the custom_target this creates.
Diffstat (limited to 'mesonbuild/modules/windows.py')
-rw-r--r-- | mesonbuild/modules/windows.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/mesonbuild/modules/windows.py b/mesonbuild/modules/windows.py index 7dd87f2..8a1fade 100644 --- a/mesonbuild/modules/windows.py +++ b/mesonbuild/modules/windows.py @@ -30,13 +30,14 @@ class WindowsModule(ExtensionModule): return compilers[l] raise MesonException('Resource compilation requires a C or C++ compiler.') - @FeatureNewKwargs('windows.compile_resources', '0.47.0', ['depend_files']) - @permittedKwargs({'args', 'include_directories', 'depend_files'}) + @FeatureNewKwargs('windows.compile_resources', '0.47.0', ['depend_files', 'depends']) + @permittedKwargs({'args', 'include_directories', 'depend_files', 'depends'}) def compile_resources(self, state, args, kwargs): comp = self.detect_compiler(state.compilers) extra_args = mesonlib.stringlistify(kwargs.get('args', [])) - wrc_deps = extract_as_list(kwargs, 'depend_files', pop = True) + wrc_depend_files = extract_as_list(kwargs, 'depend_files', pop = True) + wrc_depends = extract_as_list(kwargs, 'depends', pop = True) inc_dirs = extract_as_list(kwargs, 'include_directories', pop = True) for incd in inc_dirs: if not isinstance(incd.held_object, (str, build.IncludeDirs)): @@ -85,7 +86,8 @@ class WindowsModule(ExtensionModule): 'output': '@BASENAME@.' + suffix, 'input': [src], 'command': [rescomp] + res_args, - 'depend_files': wrc_deps, + 'depend_files': wrc_depend_files, + 'depends': wrc_depends, } if isinstance(src, str): |