aboutsummaryrefslogtreecommitdiffstats
path: root/include/image-legacy.mk
diff options
context:
space:
mode:
Diffstat (limited to 'include/image-legacy.mk')
-rw-r--r--include/image-legacy.mk22
1 files changed, 21 insertions, 1 deletions
diff --git a/include/image-legacy.mk b/include/image-legacy.mk
index 9ace98fbe5..9633500fd9 100644
--- a/include/image-legacy.mk
+++ b/include/image-legacy.mk
@@ -45,6 +45,15 @@ define LegacyDevice/Check
endif
endef
+ifdef TARGET_PER_DEVICE_ROOTFS
+ define Image/Build/Profile/Filesystem
+ cp $(KDIR)/root.$(2)+pkg=$(3) $(KDIR)/root.$(2)
+ $(call Image/Build/Profile,$(1),$(2))
+ endef
+else
+ Image/Build/Profile/Filesystem = $(Image/Build/Profile)
+endif
+
define LegacyDevice/Build
$$(_TARGET): legacy-image-$(1)
$$(_TARGET_PREPARE): legacy-image-prepare-$(1)
@@ -53,10 +62,21 @@ define LegacyDevice/Build
legacy-image-prepare-$(1):
$$(call Image/Prepare/Profile,$(1))
+ ifndef IB
+ ifdef CONFIG_TARGET_PER_DEVICE_ROOTFS
+ ROOTFS/$(1) := $(foreach fs,$(TARGET_FILESYSTEMS), \
+ $(KDIR)/root.$(fs)$$(strip $(if $(CONFIG_TARGET_PER_DEVICE_ROOTFS),+pkg=$$(ROOTFS_ID/$(1))))
+ )
+
+ $$(ROOTFS/$(1)): target-dir-$$(ROOTFS_ID/$(1))
+ legacy-images-make: $$(if $$(_PROFILE_SET),$$(ROOTFS/$(1)))
+ endif
+ endif
+
legacy-image-$(1):
$$(call Image/BuildKernel/Profile,$(1))
$(foreach fs,$(TARGET_FILESYSTEMS),
- $$(call Image/Build/Profile,$(1),$(fs))
+ $$(call Image/Build/Profile/Filesystem,$(1),$(fs),$$(ROOTFS_ID/$(1)))
)
endef