aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/modules/windows.py
diff options
context:
space:
mode:
Diffstat (limited to 'mesonbuild/modules/windows.py')
-rw-r--r--mesonbuild/modules/windows.py15
1 files changed, 10 insertions, 5 deletions
diff --git a/mesonbuild/modules/windows.py b/mesonbuild/modules/windows.py
index c16d7a8..22bf49b 100644
--- a/mesonbuild/modules/windows.py
+++ b/mesonbuild/modules/windows.py
@@ -67,11 +67,16 @@ class WindowsModule(ExtensionModule):
suffix = 'o'
if not rescomp.found():
raise MesonException('Could not find Windows resource compiler %s.' % ' '.join(rescomp.get_command()))
- res_kwargs = {'output': '@BASENAME@.' + suffix,
- 'arguments': res_args}
- res_gen = build.Generator([rescomp], res_kwargs)
- res_output = res_gen.process_files('Windows resource', args, state)
- return ModuleReturnValue(res_output, [res_output])
+
+ res_kwargs = {
+ 'output': '@BASENAME@.' + suffix,
+ 'input': args,
+ 'command': [rescomp] + res_args,
+ }
+
+ res_target = build.CustomTarget('Windows resource', state.subdir, state.subproject, res_kwargs)
+
+ return ModuleReturnValue(res_target, [res_target])
def initialize():
return WindowsModule()