mirror of
https://github.com/kiwix/libkiwix.git
synced 2025-06-26 10:11:30 +00:00
`python` binary is not installed on all platform. But `python3` is (because meson is python3). And the script we launch is python3 so use the correct version.
17 lines
593 B
Meson
17 lines
593 B
Meson
resource_files = run_command(find_program('python3'),
|
|
'-c',
|
|
'import sys; f=open(sys.argv[1]); print(f.read())',
|
|
files('resources_list.txt')
|
|
).stdout().strip().split('\n')
|
|
|
|
lib_resources = custom_target('resources',
|
|
input: 'resources_list.txt',
|
|
output: ['kiwixlib-resources.cpp', 'kiwixlib-resources.h'],
|
|
command:[res_compiler,
|
|
'--cxxfile', '@OUTPUT0@',
|
|
'--hfile', '@OUTPUT1@',
|
|
'--source_dir', '@OUTDIR@',
|
|
'@INPUT@'],
|
|
depend_files: resource_files
|
|
)
|