toolchain: report missing ports at once

Previously, ports that were needed for a scenario and that were not
prepared or outdated, triggered one assertion each during the second
build stage. The commit slots a mechanism in ahead that gathers all
these ports during the first build stage and reports them in form of a
list before the second build stage is entered.  This list can be used
directly as argument for tool/ports/prepare_port to prepare respectively
update the ports. If, however, this mechanism is not available, for
example because a target is build without the first build stage, the old
assertion still prevents the target from running into troubles with a
missing port.

Fixes #1872
This commit is contained in:
Martin Stein
2016-02-04 12:20:03 +01:00
committed by Christian Helmuth
parent 992a5ec1ae
commit ff10687a6c
9 changed files with 72 additions and 10 deletions

View File

@@ -221,6 +221,21 @@ $(INSTALL_DIR):
.PHONY: gen_deps_and_build_targets
gen_deps_and_build_targets: $(INSTALL_DIR) $(LIB_DEP_FILE)
@(echo ""; \
echo "ifneq (\$$(MISSING_PORTS),)"; \
echo "check_ports:"; \
echo " @echo \"\""; \
echo " @echo \"Error: Ports not prepared or outdated:\""; \
echo " @echo \" \$$(sort \$$(MISSING_PORTS))\""; \
echo " @echo \"\""; \
echo " @echo \"You can prepare respectively update them as follows:\""; \
echo " @echo \" <genode_dir>/tool/ports/prepare_port \$$(sort \$$(MISSING_PORTS))\""; \
echo " @echo \"\""; \
echo " @false"; \
echo "else"; \
echo "check_ports:"; \
echo "endif"; \
echo "") >> $(LIB_DEP_FILE)
@$(VERBOSE_MK)$(MAKE) $(VERBOSE_DIR) -f $(LIB_DEP_FILE) all
.PHONY: again