mirror of
https://github.com/immortalwrt/immortalwrt
synced 2025-01-09 04:29:03 +08:00
build: image: improve zip build recipe
* clean before build
* specify executable path
* allow adding extra options for zip
* use basename of $@
Signed-off-by: Sungbo Eo <mans0n@gorani.run>
(cherry picked from commit 446da70669
)
This commit is contained in:
parent
5b5a34737c
commit
e333999ecf
@ -180,11 +180,13 @@ define Build/gzip
|
||||
endef
|
||||
|
||||
define Build/zip
|
||||
rm -rf $@.tmp
|
||||
mkdir $@.tmp
|
||||
mv $@ $@.tmp/$(1)
|
||||
mv $@ $@.tmp/$(word 1,$(1))
|
||||
|
||||
TZ=UTC zip -j -X \
|
||||
$@ $@.tmp/$(if $(1),$(1),$@)
|
||||
TZ=UTC $(STAGING_DIR_HOST)/bin/zip -j -X \
|
||||
$(wordlist 2,$(words $(1)),$(1)) \
|
||||
$@ $@.tmp/$(if $(word 1,$(1)),$(word 1,$(1)),$$(basename $@))
|
||||
rm -rf $@.tmp
|
||||
endef
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user