aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/ubinize-image.sh
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2015-03-15 05:12:11 +0000
committerFelix Fietkau <nbd@openwrt.org>2015-03-15 05:12:11 +0000
commit08706120bb6c4fc7a98b6ab247f3bfd722ec9b3b (patch)
tree2433f31cf3d2f8245a793893c15f552259411158 /scripts/ubinize-image.sh
parentd9ddc95ce575ba7e892d4f5be500202e9bdbe202 (diff)
downloadupstream-08706120bb6c4fc7a98b6ab247f3bfd722ec9b3b.tar.gz
upstream-08706120bb6c4fc7a98b6ab247f3bfd722ec9b3b.tar.bz2
upstream-08706120bb6c4fc7a98b6ab247f3bfd722ec9b3b.zip
scripts: fix ubinize-image on OS X
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> SVN-Revision: 44761
Diffstat (limited to 'scripts/ubinize-image.sh')
-rwxr-xr-xscripts/ubinize-image.sh7
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/ubinize-image.sh b/scripts/ubinize-image.sh
index 6762c22bc4..b87cbb48dc 100755
--- a/scripts/ubinize-image.sh
+++ b/scripts/ubinize-image.sh
@@ -98,7 +98,11 @@ if [ ! -x "$ubinize" ]; then
exit 1
fi
-ubinizecfg="$( mktemp )"
+ubinizecfg="$( mktemp 2> /dev/null )"
+if [ -z "$ubinizecfg" ]; then
+ # try OSX signature
+ ubinizecfg="$( mktemp -t 'ubitmp' )"
+fi
ubilayout "$ubootenv" "$rootfs" "$kernel" > "$ubinizecfg"
cat "$ubinizecfg"
@@ -108,4 +112,3 @@ err="$?"
rm "$ubinizecfg"
exit $err
-