Menu

[r199]: / trunk / PackStarApp  Maximize  Restore  History

Download this file

72 lines (56 with data), 1.6 kB

#!/bin/sh

# http://code.google.com/p/tclkit/
# http://rkeene.org/projects/info/wiki/Tclkits

Tclkit=$HOME/tclkits/MacOSX/tclkit-8.5.9-macosx-universal
#Tclkit=$HOME/tclkits/MacOSX/tclkit-darwin-univ-aqua

echo "Cleaning up"
rm -f tkdiff.kit
rm -rf tkdiff.vfs
rm -rf TkDiff.app

echo "Making tkdiff into a starkit"
# Make a .kit
sdx qwrap tkdiff
if [ $? -gt 0 ]; then
  echo "sdx qwrap failed"
  exit 1
fi

# Open it into a directory tree
echo "Unwrapping the kit"
sdx unwrap tkdiff.kit
if [ $? -gt 0 ]; then
  echo "sdx unwrap failed"
  exit 1
fi
rm -f tkdiff.kit

mkdir tkdiff.vfs/lib/tkdiff
cp tkdiff tkdiff.vfs/lib/tkdiff
rm tkdiff.vfs/lib/tkdiff/tkdiff

# To test:
#tclkit tkdiff.vfs/main.tcl

echo "Converting the kit into a runtime"
sdx wrap tkdiff.kit -runtime $Tclkit

echo "Making TkDiff.app"
mkdir TkDiff.app
mkdir TkDiff.app/Contents
mkdir TkDiff.app/Contents/MacOS
mkdir TkDiff.app/Contents/Resources

echo "Copying tkdiff.kit, icons and plist into the app"
cp Info.plist TkDiff.app/Contents
cp Delta.icns TkDiff.app/Contents/Resources
mv tkdiff.kit TkDiff.app/Contents/MacOS/tkdiff

exit

# Now, on the Mac, do this:
set V = "4.2"
if ( ! -f tkdiff-$V) mkdir tkdiff-$V
mv TkDiff.app tkdiff-$V
cp LICENSE.txt tkdiff-$V
cp CHANGELOG.txt tkdiff-$V
cp README.MacOS tkdiff-$V
echo "hdiutil create -fs HFS+ -volname TkDiff-$V -srcfolder tkdiff-${V} tkdiff-$V.dmg"
hdiutil create -fs "HFS+" -volname TkDiff-$V -srcfolder tkdiff-${V} tkdiff-$V.dmg
if ($status != 0) exit

echo "Compressing DMG."
if ( -f "tkdiff-$V.dmg.gz" ) rm -f "tkdiff-$V.dmg.gz"
gzip tkdiff-$V.dmg

echo "Created:"
ls -al tkdiff-$V.dmg.gz

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.