aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/gemini/image/Makefile
diff options
context:
space:
mode:
authorMathias Kresin <dev@kresin.me>2019-01-25 21:49:46 +0100
committerMathias Kresin <dev@kresin.me>2019-01-26 15:23:37 +0100
commit10dab9b0986cda87060f8a2bf28bbac468488734 (patch)
treed102a2b9a230bf378536d17bf0e6e5c8cea6ff29 /target/linux/gemini/image/Makefile
parent98c2261ac21550b7c7bdfddc0ada508f3d7a08b4 (diff)
downloadupstream-10dab9b0986cda87060f8a2bf28bbac468488734.tar.gz
upstream-10dab9b0986cda87060f8a2bf28bbac468488734.tar.bz2
upstream-10dab9b0986cda87060f8a2bf28bbac468488734.zip
gemini: follow common pattern for temp dir naming
For temporary directories <imagename>.tmp is a common pattern in image build code across the tree. Use it for the nas4220b/sq201 recipe as well. Signed-off-by: Mathias Kresin <dev@kresin.me>
Diffstat (limited to 'target/linux/gemini/image/Makefile')
-rw-r--r--target/linux/gemini/image/Makefile18
1 files changed, 10 insertions, 8 deletions
diff --git a/target/linux/gemini/image/Makefile b/target/linux/gemini/image/Makefile
index 469e2b0a53..a55a890700 100644
--- a/target/linux/gemini/image/Makefile
+++ b/target/linux/gemini/image/Makefile
@@ -53,15 +53,17 @@ endef
# there when using OpenWRT. We just use that to create the
# "sysupgrade" firmware image.
define Build/nas4220b-sq201-images
- rm -rf $@-tmp
- mkdir -p $@-tmp
- mv $@ $@-tmp/rd.gz
- dd if=/dev/zero of=$@-tmp/hddapp.tgz bs=6144k count=1
- cp $(IMAGE_KERNEL) $@-tmp/zImage
- cp ./ImageInfo-$(1) $@-tmp/ImageInfo
- (cd $@-tmp; tar --sort=name --owner=0 --group=0 --numeric-owner -czf $@ * \
+ mkdir -p $@.tmp
+
+ mv $@ $@.tmp/rd.gz
+ dd if=/dev/zero of=$@.tmp/hddapp.tgz bs=6144k count=1
+ cp $(IMAGE_KERNEL) $@.tmp/zImage
+ cp ./ImageInfo-$(1) $@.tmp/ImageInfo
+
+ (cd $@.tmp; tar --sort=name --owner=0 --group=0 --numeric-owner -czf $@ * \
$(if $(SOURCE_DATE_EPOCH),--mtime="@$(SOURCE_DATE_EPOCH)"))
- rm -rf $@-tmp
+
+ rm -rf $@.tmp
endef
# WBD-111 and WBD-222: