kernel: remove stray 4.4 references
[openwrt/openwrt.git] / include / image-commands.mk
index 5f7845a6d921740f56e4b4f52db4e769557d1d61..4d3f025b123f44cfd48d5b6cf081ae7633577277 100644 (file)
@@ -60,7 +60,7 @@ endef
 
 define Build/netgear-dni
        $(STAGING_DIR_HOST)/bin/mkdniimg \
-               -B $(NETGEAR_BOARD_ID) -v $(VERSION_DIST).$(REVISION) \
+               -B $(NETGEAR_BOARD_ID) -v $(VERSION_DIST).$(firstword $(subst -, ,$(REVISION))) \
                $(if $(NETGEAR_HW_ID),-H $(NETGEAR_HW_ID)) \
                -r "$(1)" \
                -i $@ -o $@.new
@@ -77,17 +77,17 @@ define Build/append-squashfs-fakeroot-be
        cat $@.fakesquashfs >> $@
 endef
 
-# append a fake/empty rootfs uImage header, to fool the bootloaders
-# rootfs integrity check
-define Build/append-uImage-fakeroot-hdr
-       touch $@.fakeroot
+# append a fake/empty uImage header, to fool bootloaders rootfs integrity check
+# for example
+define Build/append-uImage-fakehdr
+       touch $@.fakehdr
        $(STAGING_DIR_HOST)/bin/mkimage \
-               -A $(LINUX_KARCH) -O linux -T filesystem -C none \
-               -n '$(call toupper,$(LINUX_KARCH)) $(VERSION_DIST) fakeroot' \
-               -d $@.fakeroot \
+               -A $(LINUX_KARCH) -O linux -T $(1) -C none \
+               -n '$(VERSION_DIST) fake $(1)' \
+               -d $@.fakehdr \
                -s \
-               $@.fakeroot
-       cat $@.fakeroot >> $@
+               $@.fakehdr
+       cat $@.fakehdr >> $@
 endef
 
 define Build/tplink-safeloader
@@ -135,7 +135,7 @@ define Build/lzma-no-dict
 endef
 
 define Build/gzip
-       gzip --force -9n -c $@ $(1) > $@.new
+       gzip -f -9n -c $@ $(1) > $@.new
        @mv $@.new $@
 endef
 
@@ -186,6 +186,10 @@ define Build/append-ubi
        rm $@.tmp
 endef
 
+define Build/append-uboot
+       dd if=$(UBOOT_PATH) >> $@
+endef
+
 define Build/pad-to
        dd if=$@ of=$@.new bs=$(1) conv=sync
        mv $@.new $@