ixp4xx: put apex images into image staging directory
authorJo-Philipp Wich <jo@mein.io>
Fri, 27 Jan 2017 15:32:41 +0000 (16:32 +0100)
committerJo-Philipp Wich <jo@mein.io>
Fri, 27 Jan 2017 15:53:31 +0000 (16:53 +0100)
Do not put the apex images into the kernel build directory as this directory
might get removed after kernel updates while the apex packages InstallDev
recipe is not getting re-executed because it is still considered current,
leading to image build failures later on due to missing images.

To ensure that built bootloader images persist over kernel version updates in
the buildroot, put them into the new STAGING_DIR_IMAGE directory.

Signed-off-by: Jo-Philipp Wich <jo@mein.io>
package/boot/apex/Makefile
target/linux/ixp4xx/image/Makefile

index fb3c77c37c9bc521bae6d3e879363550a7c08a5c..d90df8e58c8633ce17ae11aba20ebeda8b11f4f6 100644 (file)
@@ -56,7 +56,8 @@ define Package/apex/install
 endef
 
 define Build/InstallDev
 endef
 
 define Build/InstallDev
-       $(CP) $(PKG_BUILD_DIR)/out/*.bin $(KERNEL_BUILD_DIR)
+       $(INSTALL_DIR) $(STAGING_DIR_IMAGE)
+       $(CP) $(PKG_BUILD_DIR)/out/*.bin $(STAGING_DIR_IMAGE)/
 endef
 
 $(eval $(call BuildPackage,apex))
 endef
 
 $(eval $(call BuildPackage,apex))
index 7ec842064eb7cff64136b79c3382817bcdaaa0af..5b6ff0b08e18f6912f3790519f2ab394a0151067 100644 (file)
@@ -10,12 +10,12 @@ include $(INCLUDE_DIR)/image.mk
 ifdef CONFIG_PACKAGE_apex
   define Image/Build/Linksys
        BIN_DIR=$(BIN_DIR) $(TOPDIR)/scripts/slugimage.pl \
 ifdef CONFIG_PACKAGE_apex
   define Image/Build/Linksys
        BIN_DIR=$(BIN_DIR) $(TOPDIR)/scripts/slugimage.pl \
-               -L $(KDIR)/apex-$(2)-armeb.bin \
+               -L $(STAGING_DIR_IMAGE)/apex-$(2)-armeb.bin \
                -k $(BIN_DIR)/$(IMG_PREFIX)-$(2)-zImage \
                -r rootfs:$(BIN_DIR)/$(IMG_PREFIX)-$(1).img \
                -p -o $(BIN_DIR)/$(IMG_PREFIX)-$(2)-$(1).bin
        BIN_DIR=$(BIN_DIR) $(TOPDIR)/scripts/slugimage.pl \
                -k $(BIN_DIR)/$(IMG_PREFIX)-$(2)-zImage \
                -r rootfs:$(BIN_DIR)/$(IMG_PREFIX)-$(1).img \
                -p -o $(BIN_DIR)/$(IMG_PREFIX)-$(2)-$(1).bin
        BIN_DIR=$(BIN_DIR) $(TOPDIR)/scripts/slugimage.pl \
-               -F -L $(KDIR)/apex-$(2)-16mb-armeb.bin \
+               -F -L $(STAGING_DIR_IMAGE)/apex-$(2)-16mb-armeb.bin \
                -k $(BIN_DIR)/$(IMG_PREFIX)-$(2)-zImage \
                -r rootfs:$(BIN_DIR)/$(IMG_PREFIX)-$(1).img \
                -p -o $(BIN_DIR)/$(IMG_PREFIX)-$(2)-$(1)-16mb.bin
                -k $(BIN_DIR)/$(IMG_PREFIX)-$(2)-zImage \
                -r rootfs:$(BIN_DIR)/$(IMG_PREFIX)-$(1).img \
                -p -o $(BIN_DIR)/$(IMG_PREFIX)-$(2)-$(1)-16mb.bin