--- a/Admin/MacOS/App3/Info.plist Tue Jul 16 14:46:03 2013 +0200
+++ b/Admin/MacOS/App3/Info.plist Tue Jul 16 18:28:45 2013 +0200
@@ -11,11 +11,11 @@
<key>CFBundleIdentifier</key>
<string>de.tum.in.isabelle</string>
<key>CFBundleDisplayName</key>
-<string>Isabelle</string>
+<string>{ISABELLE_NAME}</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
-<string>Isabelle</string>
+<string>{ISABELLE_NAME}</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
@@ -35,7 +35,7 @@
<key>JVMOptions</key>
<array>
<string>-Dapple.laf.useScreenMenuBar=true</string>
-<string>-Disabelle.home=$APP_ROOT/Isabelle</string>
+<string>-Disabelle.home=$APP_ROOT/Contents/Resources/{ISABELLE_NAME}</string>
</array>
<key>JVMArguments</key>
<array>
--- a/Admin/MacOS/App3/mk Tue Jul 16 14:46:03 2013 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,27 +0,0 @@
-#!/bin/bash
-#
-# Make Isabelle/JVM application bundle
-
-THIS="$(cd "$(dirname "$0")"; pwd)"
-
-APP="$THIS/Isabelle.app"
-
-for NAME in Java MacOS PlugIns Resources
-do
- mkdir -p "$APP/Contents/$NAME"
-done
-
-cp "$THIS/Info.plist" "$APP/Contents/."
-
-for NAME in Pure.jar scala-library.jar scala-swing.jar
-do
- ln -sf "../Resources/Isabelle/lib/classes/ext/$NAME" "$APP/Contents/Java"
-done
-
-cp -R "$THIS/Resources/." "$APP/Contents/Resources/."
-cp "$THIS/../isabelle.icns" "$APP/Contents/Resources/."
-
-ln -sf "../Resources/Isabelle/contrib/jdk-7u13/x86_64-darwin/jdk1.7.0_13.jdk" "$APP/Contents/PlugIns/jdk"
-
-cp "$THIS/JavaAppLauncher" "$APP/Contents/MacOS/." && chmod +x "$APP/Contents/MacOS/JavaAppLauncher"
-
--- a/Admin/Release/CHECKLIST Tue Jul 16 14:46:03 2013 +0200
+++ b/Admin/Release/CHECKLIST Tue Jul 16 18:28:45 2013 +0200
@@ -50,9 +50,9 @@
Packaging
=========
-- hg up -r DISTNAME && Admin/Release/build -r DISTNAME /home/isabelle/dist
+- fully-automated packaging (requires Mac OS X):
-- manual packaging of .app (Mac OS) and .exe (Windows)
+ hg up -r DISTNAME && Admin/Release/build -r DISTNAME /home/isabelle/dist
Final release stage
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/Admin/components/bundled-macos Tue Jul 16 18:28:45 2013 +0200
@@ -0,0 +1,2 @@
+#additional components to be bundled for release
+macos_app-20130716
--- a/Admin/components/components.sha1 Tue Jul 16 14:46:03 2013 +0200
+++ b/Admin/components/components.sha1 Tue Jul 16 18:28:45 2013 +0200
@@ -32,6 +32,7 @@
8122526f1fc362ddae1a328bdbc2152853186fee jfreechart-1.0.14.tar.gz
6c737137cc597fc920943783382e928ea79e3feb kodkodi-1.2.16.tar.gz
5f95c96bb99927f3a026050f85bd056f37a9189e kodkodi-1.5.2.tar.gz
+0aab4f73ff7f5e36f33276547e10897e1e56fb1d macos_app-20130716.tar.gz
1c8cb6a8f4cbeaedce2d6d1ba8fc7e2ab3663aeb polyml-5.4.1.tar.gz
a3f9c159a0ee9a63b7a5d0c835ed9c2c908f8b56 polyml-5.5.0-1.tar.gz
7d604a99355efbfc1459d80db3279ffa7ade3e39 polyml-5.5.0-2.tar.gz
--- a/Admin/lib/Tools/makedist_bundle Tue Jul 16 14:46:03 2013 +0200
+++ b/Admin/lib/Tools/makedist_bundle Tue Jul 16 18:28:45 2013 +0200
@@ -97,8 +97,6 @@
fi
done
-mv "$ISABELLE_TARGET/contrib/windows_app" "$TMP/."
-
# purge other platforms
@@ -123,6 +121,7 @@
;;
macos)
purge_contrib '-name "x86*-linux" -o -name "x86*-cygwin" -o -name "x86*-windows"'
+ mv "$ISABELLE_TARGET/contrib/macos_app" "$TMP/."
perl -pi -e "s,lookAndFeel=.*,lookAndFeel=com.apple.laf.AquaLookAndFeel,g;" \
-e "s,delete-line.shortcut=.*,delete-line.shortcut=C+d,g;" \
@@ -131,6 +130,7 @@
;;
windows)
purge_contrib '-name "x86*-linux" -o -name "x86*-darwin"'
+ mv "$ISABELLE_TARGET/contrib/windows_app" "$TMP/."
perl -pi -e "s,lookAndFeel=.*,lookAndFeel=com.sun.java.swing.plaf.windows.WindowsLookAndFeel,g;" \
"$TMP/$ISABELLE_NAME/src/Tools/jEdit/dist/properties/jEdit.props"
@@ -175,26 +175,68 @@
# application
-if [ "$PLATFORM_FAMILY" = windows ]
+if [ "$ISABELLE_PLATFORM_FAMILY" = linux -a "$PLATFORM_FAMILY" != macos -o "$ISABELLE_PLATFORM_FAMILY" = macos ]
then
- if type -p 7z >/dev/null
- then
- (
- cd "$TMP"
- rm -f "${ARCHIVE_DIR}/${ISABELLE_NAME}.7z"
- 7z -y -bd a "$TMP/${ISABELLE_NAME}.7z" "$ISABELLE_NAME" || exit 2
-
+ case "$PLATFORM_FAMILY" in
+ macos)
echo "application for $PLATFORM_FAMILY"
(
- cat "windows_app/7zsd_All.sfx"
- cat "$ISABELLE_HOME/Admin/Windows/Installer/sfx.txt" | \
- perl -p -e "s,{ISABELLE_NAME},${ISABELLE_NAME},g;"
- cat "$TMP/${ISABELLE_NAME}.7z"
- ) > "${ARCHIVE_DIR}/${ISABELLE_NAME}.exe"
- chmod +x "${ARCHIVE_DIR}/${ISABELLE_NAME}.exe"
- )
- fi
+ cd "$TMP"
+
+ APP_TEMPLATE="$ISABELLE_HOME/Admin/MacOS/App3"
+ APP="${ISABELLE_NAME}.app"
+
+ for NAME in Java MacOS PlugIns Resources
+ do
+ mkdir -p "$APP/Contents/$NAME"
+ done
+
+ cat "$APP_TEMPLATE/Info.plist" | \
+ perl -p -e "s,{ISABELLE_NAME},${ISABELLE_NAME},g;" > "$APP/Contents/Info.plist"
+
+ for NAME in Pure.jar scala-library.jar scala-swing.jar
+ do
+ ln -sf "../Resources/${ISABELLE_NAME}/lib/classes/ext/$NAME" "$APP/Contents/Java"
+ done
+
+ cp -R "$APP_TEMPLATE/Resources/." "$APP/Contents/Resources/."
+ cp "$APP_TEMPLATE/../isabelle.icns" "$APP/Contents/Resources/."
+
+ ln -sf "../Resources/${ISABELLE_NAME}/contrib/jdk-7u21/x86_64-darwin/jdk1.7.0_21.jdk" \
+ "$APP/Contents/PlugIns/jdk"
+
+ cp macos_app/JavaAppLauncher "$APP/Contents/MacOS/." && \
+ chmod +x "$APP/Contents/MacOS/JavaAppLauncher"
+
+ mv "$ISABELLE_NAME" "$APP/Contents/Resources/."
+ ln -sf "Contents/Resources/$ISABELLE_NAME" "$APP/Isabelle"
+
+ hdiutil create -srcfolder "$APP" "${ARCHIVE_DIR}/${ISABELLE_NAME}.dmg"
+ )
+ ;;
+ windows)
+ (
+ cd "$TMP"
+ rm -f "${ARCHIVE_DIR}/${ISABELLE_NAME}.7z"
+ 7z -y -bd a "$TMP/${ISABELLE_NAME}.7z" "$ISABELLE_NAME" || exit 2
+
+ echo "application for $PLATFORM_FAMILY"
+ (
+ cat "windows_app/7zsd_All.sfx"
+ cat "$ISABELLE_HOME/Admin/Windows/Installer/sfx.txt" | \
+ perl -p -e "s,{ISABELLE_NAME},${ISABELLE_NAME},g;"
+ cat "$TMP/${ISABELLE_NAME}.7z"
+ ) > "${ARCHIVE_DIR}/${ISABELLE_NAME}.exe"
+ chmod +x "${ARCHIVE_DIR}/${ISABELLE_NAME}.exe"
+ )
+ ;;
+ *)
+ ;;
+ esac
+else
+ echo "### Cannot build application for $PLATFORM_FAMILY on $ISABELLE_PLATFORM_FAMILY"
fi
+
# clean up
rm -rf "$TMP"