Commit eb78744
create mac disc image
Changed files (3)
Diff
@@ -1,26 +1,48 @@ <?xml version="1.0" encoding="UTF-8"?>-!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">+<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict>- <key>CFBundleGetInfoString</key>- <string>Birdfont</string>- <key>CFBundleExecutable</key>- <string>birdfont.sh</string>- <key>CFBundleIdentifier</key>- <string>org.birdfont</string>- <key>CFBundleName</key>- <string>birdfont</string>- <key>CFBundleIconFile</key>- <string>birdfont.icns</string>- <key>CFBundleShortVersionString</key>- <string>0.01</string>- <key>CFBundleInfoDictionaryVersion</key>- <string>6.0</string>- <key>CFBundlePackageType</key>- <string>APPL</string>- <key>IFMajorVersion</key>- <integer>0</integer>- <key>IFMinorVersion</key>- <integer>9</integer>+ <key>CFBundleDevelopmentRegion</key>+ <string>English</string>+ <key>CFBundleDisplayName</key>+ <string>birdfont</string>+ <key>CFBundleExecutable</key>+ <string>birdfont.sh</string>+ <key>CFBundleGetInfoString</key>+ <string>Birdfont</string>+ <key>CFBundleIconFile</key>+ <string>birdfont.icns</string>+ <key>CFBundleIdentifier</key>+ <string>org.birdfont</string>+ <key>CFBundleInfoDictionaryVersion</key>+ <string>6.0</string>+ <key>CFBundleName</key>+ <string>makeBundle</string>+ <key>CFBundlePackageType</key>+ <string>APPL</string>+ <key>CFBundleShortVersionString</key>+ <string>1.0</string>+ <key>CFBundleSignature</key>+ <string>nono</string>+ <key>CFBundleVersion</key>+ <string>1.0</string>+ <key>LSEnvironment</key>+ <dict>+ <key>APP_BUNDLER</key>+ <string>makeBundle.tcl 1.0</string>+ </dict>+ <key>LSHasLocalizedDisplayName</key>+ <false/>+ <key>LSUIElement</key>+ <false/>+ <key>NSAppleScriptEnabled</key>+ <false/>+ <key>NSHumanReadableCopyright</key>+ <string>Birdfont Copyright Johan Mattsson and others. See AUTHORS file.</string>+ <key>NSMainNibFile</key>+ <string>MainMenu</string>+ <key>NSPrincipalClass</key>+ <string>NSApplication</string> </dict>-</plist>\ No newline at end of file+</plist>+@@ -89,6 +89,9 @@ def build(): run("gcc build/mac/birdfont-export/*.o ./build/mac/bin/libbirdfont.dylib $(pkg-config --cflags --libs libxml-2.0) $(pkg-config --cflags --libs gio-2.0) $(pkg-config --cflags --libs cairo) $(pkg-config --cflags --libs glib-2.0) $(pkg-config --cflags --libs gdk-pixbuf-2.0) $(pkg-config --cflags --libs webkit-1.0) $(pkg-config --cflags --libs gtk+-2.0) -o ./build/mac/bin/birdfont-export") + # clean+ run("rm -rf build/mac/birdfont.app")+ # copy files run("mkdir -p build/mac/birdfont.app") run("mkdir -p build/mac/birdfont.app/Contents")@@ -97,7 +100,7 @@ def build(): run("cp build/mac/bin/* build/mac/birdfont.app/Contents/MacOs") run("cp mac/birdfont.sh build/mac/birdfont.app/Contents/MacOs")- run("cp mac/Info.plist build/mac/birdfont.app/")+ run("cp mac/Info.plist build/mac/birdfont.app/Contents/") run("cp -r layout build/mac/birdfont.app/Contents/MacOs") run("cp -r icons build/mac/birdfont.app/Contents/MacOs") run("cp mac/birdfont.icns build/mac/birdfont.app/Contents/Resources")@@ -131,6 +134,7 @@ def build(): run("install_name_tool -change /usr/local/lib/libbirdfont.dylib @executable_path/libbirdfont.dylib " + "build/mac/birdfont.app/Contents/MacOs/birdfont-export") + # run("rm -rf build/mac/birdfont.dmg") # run("hdiutil create -megabytes 50 -fs HFS+ -volname birdfont build/mac/birdfont") # run("open build/mac/birdfont.dmg") new file mode 100755@@ -0,0 +1,21 @@+#!/usr/bin/python++import os+import shutil+import subprocess+import sys++def run(cmd):+ process = subprocess.Popen (cmd, shell=True)+ process.communicate()[0]+ if not process.returncode == 0:+ print("Error: " + cmd)+ exit(1)+ +def create_dmg ():+ run("rm -rf build/mac/birdfont.dmg") + run("hdiutil create -megabytes 55 -fs HFS+ -volname birdfont build/mac/birdfont")+ # run("cp -r build/mac/birdfont.app /Volumes/birdfont/")+ print ("Copy the files with Finder, we don't know the path here.")++create_dmg ()\ No newline at end of file