Browse Source

Update mkmacdmg

pull/45/head
Jonathan "Duke" Leto 5 years ago
parent
commit
df247f4df3
  1. 34
      src/scripts/mkmacdmg.sh
  2. 2
      src/scripts/signbinaries.sh

34
src/scripts/mkmacdmg.sh

@ -12,8 +12,8 @@ case $key in
shift # past argument
shift # past value
;;
-z|--zcash_path)
ZCASH_DIR="$2"
-h|--hush_path)
HUSH_DIR="$2"
shift # past argument
shift # past value
;;
@ -35,8 +35,8 @@ if [ -z $QT_PATH ]; then
exit 1;
fi
if [ -z $ZCASH_DIR ]; then
echo "ZCASH_DIR is not set. Please set it to the base directory of a compiled zcashd";
if [ -z $HUSH_DIR ]; then
echo "HUSH_DIR is not set. Please set it to the base directory of a compiled hushd";
exit 1;
fi
@ -45,8 +45,8 @@ if [ -z $APP_VERSION ]; then
exit 1;
fi
if [ ! -f $ZCASH_DIR/src/zcashd ]; then
echo "Could not find compiled zcashd in $ZCASH_DIR/src/.";
if [ ! -f $HUSH_DIR/src/hushd ]; then
echo "Could not find compiled hushd in $HUSH_DIR/src/.";
exit 1;
fi
@ -60,7 +60,7 @@ export PATH=$PATH:/usr/local/bin
#Clean
echo -n "Cleaning..............."
make distclean >/dev/null 2>&1
rm -f artifacts/macOS-zecwallet-v$APP_VERSION.dmg
rm -f artifacts/macOS-silentdragon-v$APP_VERSION.dmg
echo "[OK]"
@ -78,27 +78,29 @@ echo "[OK]"
#Qt deploy
echo -n "Deploying.............."
mkdir artifacts >/dev/null 2>&1
rm -f artifcats/zecwallet.dmg >/dev/null 2>&1
rm -f artifcats/silentdragon.dmg >/dev/null 2>&1
rm -f artifacts/rw* >/dev/null 2>&1
cp $ZCASH_DIR/src/zcashd zecwallet.app/Contents/MacOS/
cp $ZCASH_DIR/src/zcash-cli zecwallet.app/Contents/MacOS/
$QT_PATH/bin/macdeployqt zecwallet.app
cp $HUSH_DIR/src/hushd silentdragon.app/Contents/MacOS/
cp $HUSH_DIR/src/hush-cli silentdragon.app/Contents/MacOS/
cp $HUSH_DIR/src/komodod silentdragon.app/Contents/MacOS/
cp $HUSH_DIR/src/komodo-cli silentdragon.app/Contents/MacOS/
$QT_PATH/bin/macdeployqt silentdragon.app
echo "[OK]"
echo -n "Building dmg..........."
mv zecwallet.app ZecWallet.app
create-dmg --volname "ZecWallet-v$APP_VERSION" --volicon "res/logo.icns" --window-pos 200 120 --icon "ZecWallet.app" 200 190 --app-drop-link 600 185 --hide-extension "ZecWallet.app" --window-size 800 400 --hdiutil-quiet --background res/dmgbg.png artifacts/macOS-zecwallet-v$APP_VERSION.dmg ZecWallet.app >/dev/null 2>&1
mv silentdragon.app silentdragon.app
create-dmg --volname "silentdragon-v$APP_VERSION" --volicon "res/logo.icns" --window-pos 200 120 --icon "silentdragon.app" 200 190 --app-drop-link 600 185 --hide-extension "silentdragon.app" --window-size 800 400 --hdiutil-quiet --background res/dmgbg.png artifacts/macOS-silentdragon-v$APP_VERSION.dmg silentdragon.app >/dev/null 2>&1
#mkdir bin/dmgbuild >/dev/null 2>&1
#sed "s/RELEASE_VERSION/${APP_VERSION}/g" res/appdmg.json > bin/dmgbuild/appdmg.json
#cp res/logo.icns bin/dmgbuild/
#cp res/dmgbg.png bin/dmgbuild/
#cp -r zecwallet.app bin/dmgbuild/
#cp -r silentdragon.app bin/dmgbuild/
#appdmg --quiet bin/dmgbuild/appdmg.json artifacts/macOS-zecwallet-v$APP_VERSION.dmg >/dev/null
if [ ! -f artifacts/macOS-zecwallet-v$APP_VERSION.dmg ]; then
#appdmg --quiet bin/dmgbuild/appdmg.json artifacts/macOS-silentdragon-v$APP_VERSION.dmg >/dev/null
if [ ! -f artifacts/macOS-silentdragon-v$APP_VERSION.dmg ]; then
echo "[ERROR]"
exit 1
fi

2
src/scripts/signbinaries.sh

@ -35,7 +35,7 @@ rm -f signatures-v$APP_VERSION.tar.gz
# sha256sum the binaries
gsha256sum *$APP_VERSION* > sha256sum-v$APP_VERSION.txt
for i in $( ls *zecwallet-v$APP_VERSION* sha256sum-v$APP_VERSION* ); do
for i in $( ls *silentdragon-v$APP_VERSION* sha256sum-v$APP_VERSION* ); do
echo "Signing" $i
gpg --batch --output ../release/signatures/$i.sig --detach-sig $i
done

Loading…
Cancel
Save