core-dependencies: remove unneeded HOSTCC
PATCH 1/2 core-dependencies: remove unneeded HOSTCC
dependencies.sh uses HOSTCC_NOCCACHE directly, and this variable is exported from the top-level Makefile, so there is no need to pass HOSTCC to it. HOSTCC is not used at all in dependencies.sh.
Thus, we also no longer need to apply the HOSTCC override for core-dependencies. The core-depencies rule doesn't use HOSTCC or HOSTCXX.
--- support/dependencies/dependencies.mk | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
support/dependencies/dependencies.mk +3 -4
@@ -19,12 +19,11 @@ DEPENDENCIES_HOST_PREREQ += host-ccache endif core-dependencies: - @HOSTCC="$(firstword $(HOSTCC))" MAKE="$(MAKE)" \ - DL_TOOLS="$(sort $(DL_TOOLS_DEPENDENCIES))" \ + @MAKE="$(MAKE)" DL_TOOLS="$(sort $(DL_TOOLS_DEPENDENCIES))" \ $(TOPDIR)/support/dependencies/dependencies.sh -core-dependencies $(DEPENDENCIES_HOST_PREREQ): HOSTCC=$(HOSTCC_NOCCACHE) -core-dependencies $(DEPENDENCIES_HOST_PREREQ): HOSTCXX=$(HOSTCXX_NOCCACHE) +$(DEPENDENCIES_HOST_PREREQ): HOSTCC=$(HOSTCC_NOCCACHE) +$(DEPENDENCIES_HOST_PREREQ): HOSTCXX=$(HOSTCXX_NOCCACHE) dependencies: core-dependencies $(DEPENDENCIES_HOST_PREREQ) ################################################################################
Signature · 1 line
2.15.0.rc1
PATCH 2/2 dependencies: correct dependencies for top-level parallel build
Commit 4932c8a7cc94277b3d53cecd935f725b91cfa9fe introduced the core-dependencies target to make sure that the dependencies.sh script runs before we attempt to compile any host tool, so that the absence of a compiler is properly detected. However, this relied on the left-to-right evaluation of dependencies. This will no longer be true when we enable top-level parallel build.
Fix this by letting DEPENDENCIES_HOST_PREREQ depend on core-dependencies.
Note that it is not possible to remove the
dependencies <- core-dependencies. Indeed, it is possible that DEPENDENCIES_HOST_PREREQ is completely empty, and in that case we still need to check core-dependencies.
--- support/dependencies/dependencies.mk | 2 ++ 1 file changed, 2 insertions(+)
support/dependencies/dependencies.mk +2 -0
@@ -24,6 +24,8 @@ core-dependencies: $(DEPENDENCIES_HOST_PREREQ): HOSTCC=$(HOSTCC_NOCCACHE) $(DEPENDENCIES_HOST_PREREQ): HOSTCXX=$(HOSTCXX_NOCCACHE) +$(DEPENDENCIES_HOST_PREREQ): core-dependencies + dependencies: core-dependencies $(DEPENDENCIES_HOST_PREREQ) ################################################################################
Signature · 1 line
2.15.0.rc1
PATCH 1/2 core-dependencies: remove unneeded HOSTCC
In reply to Arnout Vandecappelle (Essensium/Mind)Hello,
Quoted 4 lines · Arnout Vandecappelle (Essensium/Mind)
dependencies.shusesHOSTCC_NOCCACHEdirectly, and this variable is exported from the top-levelMakefile, so there is no need to pass HOSTCC to it. HOSTCC is not used at all independencies.sh.
Quoted 8 lines
Thus, we also no longer need to apply the HOSTCC override for core-dependencies. The core-depencies rule doesn't use HOSTCC or HOSTCXX.
--- support/dependencies/dependencies.mk | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
Both patches applied. Thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com