build: Make the completion depend on the Toolbx binary

Fallout from bafbbe81c9

https://github.com/containers/toolbox/pull/1055
https://github.com/containers/toolbox/pull/1115
This commit is contained in:
Ondřej Míchal 2022-05-20 20:17:33 +03:00 committed by Debarshi Ray
parent 284a2bdf39
commit 6c0b045e1a
2 changed files with 4 additions and 1 deletions

View file

@ -17,6 +17,7 @@ endif
completion_bash = custom_target('bash-completion', completion_bash = custom_target('bash-completion',
capture: true, capture: true,
command: [generate_completions_program, meson.global_source_root() / 'src', 'bash'], command: [generate_completions_program, meson.global_source_root() / 'src', 'bash'],
depends: [toolbox],
install: true, install: true,
install_dir: bash_comp_dir, install_dir: bash_comp_dir,
output: 'toolbox') output: 'toolbox')
@ -24,6 +25,7 @@ completion_bash = custom_target('bash-completion',
completion_zsh = custom_target('zsh-completion', completion_zsh = custom_target('zsh-completion',
capture: true, capture: true,
command: [generate_completions_program, meson.global_source_root() / 'src', 'zsh'], command: [generate_completions_program, meson.global_source_root() / 'src', 'zsh'],
depends: [toolbox],
install: true, install: true,
install_dir: get_option('datadir') / 'zsh' / 'site_functions', install_dir: get_option('datadir') / 'zsh' / 'site_functions',
output: '_toolbox') output: '_toolbox')
@ -31,6 +33,7 @@ completion_zsh = custom_target('zsh-completion',
completion_fish = custom_target('fish-completion', completion_fish = custom_target('fish-completion',
capture: true, capture: true,
command: [generate_completions_program, meson.global_source_root() / 'src', 'fish'], command: [generate_completions_program, meson.global_source_root() / 'src', 'fish'],
depends: [toolbox],
install: true, install: true,
install_dir: fish_comp_dir, install_dir: fish_comp_dir,
output: 'toolbox.fish') output: 'toolbox.fish')

View file

@ -48,7 +48,7 @@ endif
message('Host machine dynamic linker:', dynamic_linker) message('Host machine dynamic linker:', dynamic_linker)
custom_target( toolbox = custom_target(
'toolbox', 'toolbox',
build_by_default: true, build_by_default: true,
command: [ command: [