Admin/lib/Tools/makedist_bundle
changeset 69130 80494b8323fa
parent 68375 5714e8806060
child 69389 16f17828adb1
equal deleted inserted replaced
69129:40df88947850 69130:80494b8323fa
   156     done
   156     done
   157   )
   157   )
   158 }
   158 }
   159 
   159 
   160 
   160 
   161 # purge jdk -- keep only jre
       
   162 
       
   163 function purge_jdk
       
   164 {
       
   165   local DIR="contrib/jdk/$1"
       
   166   (
       
   167     cd "$ISABELLE_TARGET"
       
   168     if [ -d "$DIR/jre" ]; then
       
   169       for X in "$DIR"/*
       
   170       do
       
   171         case "$X" in
       
   172           */jre) ;;
       
   173           *)
       
   174             echo "removing $X"
       
   175             rm -rf "$X"
       
   176             ;;
       
   177         esac
       
   178       done
       
   179     else
       
   180       fail "Bad JDK directory: \"$DIR\""
       
   181     fi
       
   182   )
       
   183 }
       
   184 
       
   185 
       
   186 # platform-specific setup (inside archive)
   161 # platform-specific setup (inside archive)
   187 
   162 
   188 case "$PLATFORM_FAMILY" in
   163 case "$PLATFORM_FAMILY" in
   189   linux)
   164   linux)
   190     purge_target 'contrib -name "x86*-darwin" -o -name "x86*-cygwin" -o -name "x86*-windows"'
   165     purge_target 'contrib -name "x86*-darwin" -o -name "x86*-cygwin" -o -name "x86*-windows"'
   191     purge_jdk "x86_64-linux"
       
   192 
   166 
   193     (
   167     (
   194       init_component "$JEDIT_HOME"
   168       init_component "$JEDIT_HOME"
   195 
   169 
   196       echo "# Java runtime options"
   170       echo "# Java runtime options"
   219     mv "$ISABELLE_TARGET/contrib/linux_app" "$TMP/."
   193     mv "$ISABELLE_TARGET/contrib/linux_app" "$TMP/."
   220     cp "$TMP/linux_app/Isabelle" "$ISABELLE_TARGET/$ISABELLE_NAME"
   194     cp "$TMP/linux_app/Isabelle" "$ISABELLE_TARGET/$ISABELLE_NAME"
   221     ;;
   195     ;;
   222   macos)
   196   macos)
   223     purge_target 'contrib -name "x86*-linux" -o -name "x86*-cygwin" -o -name "x86*-windows"'
   197     purge_target 'contrib -name "x86*-linux" -o -name "x86*-cygwin" -o -name "x86*-windows"'
   224     purge_jdk "x86_64-darwin/Contents/Home"
       
   225     mv "$ISABELLE_TARGET/contrib/macos_app" "$TMP/."
   198     mv "$ISABELLE_TARGET/contrib/macos_app" "$TMP/."
   226 
   199 
   227     perl -pi \
   200     perl -pi \
   228       -e "s,lookAndFeel=.*,lookAndFeel=com.apple.laf.AquaLookAndFeel,g;" \
   201       -e "s,lookAndFeel=.*,lookAndFeel=com.apple.laf.AquaLookAndFeel,g;" \
   229       -e "s,delete-line.shortcut=.*,delete-line.shortcut=C+d,g;" \
   202       -e "s,delete-line.shortcut=.*,delete-line.shortcut=C+d,g;" \
   231       -e "s,plugin-blacklist.MacOSX.jar=true,plugin-blacklist.MacOSX.jar=,g;" \
   204       -e "s,plugin-blacklist.MacOSX.jar=true,plugin-blacklist.MacOSX.jar=,g;" \
   232       "$ISABELLE_TARGET/src/Tools/jEdit/dist/properties/jEdit.props"
   205       "$ISABELLE_TARGET/src/Tools/jEdit/dist/properties/jEdit.props"
   233     ;;
   206     ;;
   234   windows)
   207   windows)
   235     purge_target 'contrib -name "x86*-linux" -o -name "x86*-darwin" -o -name "x86-cygwin"'
   208     purge_target 'contrib -name "x86*-linux" -o -name "x86*-darwin" -o -name "x86-cygwin"'
   236     purge_jdk "x86_64-windows"
       
   237 
   209 
   238     mv "$ISABELLE_TARGET/contrib/windows_app" "$TMP/."
   210     mv "$ISABELLE_TARGET/contrib/windows_app" "$TMP/."
   239 
   211 
   240     perl -pi \
   212     perl -pi \
   241       -e "s,lookAndFeel=.*,lookAndFeel=com.sun.java.swing.plaf.windows.WindowsLookAndFeel,g;" \
   213       -e "s,lookAndFeel=.*,lookAndFeel=com.sun.java.swing.plaf.windows.WindowsLookAndFeel,g;" \