X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/b2363fac89ec337da6c1ba78a230f8972dba8b0c..bf82d1e1fa09243728f245651ded9b8fbd6d3f09:/target/linux/image/squashfs.mk diff --git a/target/linux/image/squashfs.mk b/target/linux/image/squashfs.mk index 3811567a0..184330cfe 100644 --- a/target/linux/image/squashfs.mk +++ b/target/linux/image/squashfs.mk @@ -1,26 +1,36 @@ -squashfs-prepare: +ifneq ($(CONFIG_BIG_ENDIAN),y) +endian := le +else +endian := be +endif + +squashfs-prepare: FORCE $(MAKE) -C squashfs prepare -squashfs-compile: +squashfs-compile: prepare-targets $(MAKE) -C squashfs compile -squashfs-clean: +squashfs-clean: FORCE $(MAKE) -C squashfs clean rm -f $(KDIR)/root.squashfs $(KDIR)/root.squashfs: install-prepare - @mkdir -p $(KDIR)/root/jffs - $(STAGING_DIR)/bin/mksquashfs-lzma $(KDIR)/root $@ -nopad -noappend -root-owned -le + @mkdir -p $(BUILD_DIR)/root/jffs + $(STAGING_DIR)/bin/mksquashfs-lzma $(BUILD_DIR)/root $@ -nopad -noappend -root-owned -$(endian) + +ifeq ($(IB),) +squashfs-install: compile-targets $(BOARD)-compile +endif -squashfs-install: $(KDIR)/root.squashfs +squashfs-install: $(KDIR)/root.squashfs FORCE $(MAKE) -C $(BOARD) install KERNEL="$(KERNEL)" FS="squashfs" -squashfs-install-ib: +squashfs-install-ib: compile-targets mkdir -p $(IB_DIR)/staging_dir_$(ARCH)/bin - cp $(STAGING_DIR)/bin/mksquashfs-lzma $(IB_DIR)/staging_dir_$(ARCH)/bin + $(CP) $(STAGING_DIR)/bin/mksquashfs-lzma $(IB_DIR)/staging_dir_$(ARCH)/bin -prepare: squashfs-prepare -compile: squashfs-compile -install: squashfs-install +prepare-targets: squashfs-prepare +compile-targets: squashfs-compile +install-targets: squashfs-install install-ib: squashfs-install-ib clean: squashfs-clean