From: Hauke Mehrtens Date: Tue, 2 Oct 2018 20:43:58 +0000 (+0200) Subject: image: ignore usign build errors X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=5933958168c84d7ade94ce8bec451da2df064ead;p=openwrt%2Fstaging%2Fzorun.git image: ignore usign build errors The tl-wa850re-v2 images from the ar71xx/tiny target are getting too big with the default packages. The size check is done before the meta data is added so there is no file to add meta data to or to sign. Originally errors in Build/append-metadata were getting ignored, but if the signing fails the error is not ignored. This adds a check if the file to be signed is there and only does the signing if it is there. This way it does not fail if the package creation was already aborted earlier. Fixes: 848b455d2e94 ("image: use ucert to append signature") Signed-off-by: Hauke Mehrtens --- diff --git a/include/image-commands.mk b/include/image-commands.mk index ae01706b14..05d36093d3 100644 --- a/include/image-commands.mk +++ b/include/image-commands.mk @@ -332,7 +332,7 @@ metadata_json = \ define Build/append-metadata $(if $(SUPPORTED_DEVICES),-echo $(call metadata_json,$(SUPPORTED_DEVICES)) | fwtool -I - $@) - [ ! -s "$(BUILD_KEY)" -o ! -s "$(BUILD_KEY).ucert" ] || { \ + [ ! -s "$(BUILD_KEY)" -o ! -s "$(BUILD_KEY).ucert" -o ! -s "$@" ] || { \ cp "$(BUILD_KEY).ucert" "$@.ucert" ;\ usign -S -m "$@" -s "$(BUILD_KEY)" -x "$@.sig" ;\ ucert -A -c "$@.ucert" -x "$@.sig" ;\