From 44d1465db0660de6fed5a8fae1bece92767c7e7f Mon Sep 17 00:00:00 2001 From: Amar Takhar Date: Mon, 29 Dec 2008 10:36:21 +0000 Subject: [PATCH] * Add 'make osx-dmg' target * Fix scripts/osx-dmg.sh to check for ${PKG_DIR}.app before making a dmg. Originally committed to SVN as r2559. --- Makefile.am | 2 ++ scripts/osx-dmg.sh | 7 ++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/Makefile.am b/Makefile.am index dfb1ad818..abf546af8 100644 --- a/Makefile.am +++ b/Makefile.am @@ -30,6 +30,8 @@ SUBDIRS = \ osx-bundle: /bin/sh scripts/osx-bundle.sh @PACKAGE_TARNAME@-@PACKAGE_VERSION@ +osx-dmg: + /bin/sh scripts/osx-dmg.sh @PACKAGE_TARNAME@-@PACKAGE_VERSION@ "@PACKAGE_TARNAME@ @PACKAGE_VERSION@" EXTRA_DIST = \ intltool-extract.in \ diff --git a/scripts/osx-dmg.sh b/scripts/osx-dmg.sh index 7b5a44f4a..4ed027897 100755 --- a/scripts/osx-dmg.sh +++ b/scripts/osx-dmg.sh @@ -11,11 +11,16 @@ # Released under GNU GPL, read the file 'COPYING' for more information TMP_DMG="temp_dmg" -PKG_DIR="${1}" +PKG_DIR="${1}.app" PKG_NAME="${2}" PKG_NAME_RW="${1}_rw.dmg" PKG_NAME_VOLUME="${2}" +if ! test -d "${PKG_DIR}"; then + echo "${PKG_DIR} does not exist, please run 'make osx-bundle'" + exit 1; +fi + mkdir -v ${TMP_DMG} echo echo "---- Copying ${1} into ${TMP_DMG}/ ----"