contrib: meson-machinefile provide the binary from makefile

Provide the necessary binary overrides throught the machine files
exposing the contribs, and ensure that the meson-machinefile built
depends on which binaries are built.

The new build tool generation uses a new PKGS.tools variable which
should match with the names used to find the different programs.

Not all programs can be found this way. For instance, it seems that the
Qt module from meson will completely ignore this parameter and load for
the Qt installation anyway.
This commit is contained in:
Alexandre Janniaux 2024-04-15 09:38:47 +02:00 committed by Steve Lhomme
parent d9793296c5
commit e53da4bf08
1 changed files with 5 additions and 1 deletions

View File

@ -16,9 +16,13 @@ endif
meson-machinefile:
mkdir -p $@
meson-machinefile/contrib.ini: $(foreach tool,$(filter-out $(PKGS_FOUND),$(PKGS.tools)),.dep-$(tool))
meson-machinefile/contrib.ini: $(SRC)/gen-meson-machinefile.py meson-machinefile
PREFIX="$(PREFIX)" \
$(SRC)/gen-meson-machinefile.py --type external-$(CROSS_OR_NATIVE) $@
$(SRC)/gen-meson-machinefile.py \
--type external-$(CROSS_OR_NATIVE) \
$(foreach tool,$(filter-out $(PKGS_FOUND),$(PKGS.tools)),--binary $(tool):$(PKGS.tools.$(tool).path)) \
$@
# Dummy target, there is nothing to check
# as we download nothing.