Makefile: ensure system is built even if no filesystem image is selected
PATCH 1/1 Makefile: ensure system is built even if no filesystem image is selected
The parallel build patch series has significantly reworked how some of the core dependencies are expressed. We now have the following dependencies:
all: world
world: target-post-image
target-post-image: $(TARGETS_ROOTFS)
with TARGETS_ROOTFS containing the list of root filesystem image targets, each having the following dependencies:
$$(BINARIES_DIR)/rootfs.$(1): target-finalize $$(ROOTFS_$(2)_DEPENDENCIES)
The bottom line is that the "target-finalize" target, which in turns ensures that all packages are built, is only triggered if at least one filesystem image is enabled.
As we want to support builds with no filesystem image selected, this is not acceptable. As a fix, we change the target-post-image target to:
target-post-image: $(TARGETS_ROOTFS) target-finalize
This way, target-finalize will be triggered even if TARGETS_ROOTFS is empty. This is still correct for parallel build, as the individual root filesystem image targets still depend on target-finalize.
--- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Makefile +1 -1
@@ -620,7 +620,7 @@ target-generatelocales: host-localedef done endif -target-post-image: $(TARGETS_ROOTFS) +target-post-image: $(TARGETS_ROOTFS) target-finalize @$(foreach s, $(call qstrip,$(BR2_ROOTFS_POST_IMAGE_SCRIPT)), \ $(call MESSAGE,"Executing post-image script $(s)"); \ $(USER_HOOKS_EXTRA_ENV) $(s) $(BINARIES_DIR) $(call qstrip,$(BR2_ROOTFS_POST_SCRIPT_ARGS))$(sep))
Signature · 1 line
1.8.3.2
PATCH 1/1 Makefile: ensure system is built even if no filesystem image is selected
Quoted 1 line · Thomas Petazzoni
Signed-off-by Thomas Petazzoni <[email protected]>
PATCH 1/1 Makefile: ensure system is built even if no filesystem image is selected
Quoted 5 lines · Gustavo Zacarias
Quoted 1 line · Thomas Petazzoni
Signed-off-by Thomas Petazzoni <[email protected]>Acked-by Gustavo Zacarias <[email protected]>
Thanks
Signature · 1 line
Fabio Porcedda
Thomas Petazzoni
AppliedPATCH 1/1 Makefile: ensure system is built even if no filesystem image is selected
In reply to Thomas PetazzoniDear Thomas Petazzoni,
Quoted 23 lines · Thomas Petazzoni
The parallel build patch series has significantly reworked how some of the core dependencies are expressed. We now have the following dependencies:
all: world
world: target-post-image
target-post-image: $(TARGETS_ROOTFS)with
TARGETS_ROOTFScontaining the list of root filesystem image targets, each having the following dependencies:$$(BINARIES_DIR)/rootfs.$(1): target-finalize $$(ROOTFS_$(2)_DEPENDENCIES)
The bottom line is that the "target-finalize" target, which in turns ensures that all packages are built, is only triggered if at least one filesystem image is enabled.
As we want to support builds with no filesystem image selected, this is not acceptable. As a fix, we change the target-post-image target to:
target-post-image: $(TARGETS_ROOTFS) target-finalize
Quoted 8 lines
This way, target-finalize will be triggered even if
TARGETS_ROOTFSis empty. This is still correct for parallel build, as the individual root filesystem image targets still depend on target-finalize.Signed-off-by Thomas Petazzoni <[email protected]>--- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Applied.
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com