meson: create vlc-cache-gen & plugins.dat

This commit is contained in:
Ankit Meel 2024-04-21 08:11:05 +00:00 committed by Steve Lhomme
parent a49403442e
commit b53cc653ea
1 changed files with 16 additions and 0 deletions

View File

@ -39,4 +39,20 @@ if build_vlc and (host_system != 'darwin' or have_osx)
objc_args: [vlc_top_builddir_def, vlc_top_srcdir_def],
win_subsystem: 'windows'
)
vlc_cache_gen_dep = executable('vlc-cache-gen',
['cachegen.c'],
link_with: [vlc_libcompat, libvlc],
include_directories: [vlc_include_dirs],
)
plugins_dat = custom_target('plugins.dat',
# `vlc_cache_gen_dep.full_path()` doesn't work since the executable is not built yet.
# `vlc_cache_gen_dep` creates a build order dependency.
command: [vlc_cache_gen_dep, meson.global_build_root() / 'modules'],
# ninja command will be `ninja bin/plugins.dat`
output: 'plugins.dat',
build_by_default: true,
)
endif