Skip to content

Commit

Permalink
Builder|Mac OS X: Updated disk image template
Browse files Browse the repository at this point in the history
A sparsebundle image takes up less space.
  • Loading branch information
skyjake committed Mar 26, 2012
1 parent 3505a8d commit 9474c8f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 6 deletions.
12 changes: 6 additions & 6 deletions distrib/platform_release.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,13 +198,13 @@ def mac_release():

masterDmg = target
volumeName = "Doomsday Engine " + DOOMSDAY_VERSION_FULL
templateFile = os.path.join(SNOWBERRY_DIR, 'template-image/template.dmg')
templateFile = os.path.join(SNOWBERRY_DIR, 'template-image/template.sparseimage')
if not os.path.exists(templateFile):
print 'Template .dmg not found, trying to extract from compressed archive...'
print 'Template .sparseimage not found, trying to extract from compressed archive...'
os.system('bunzip2 -k "%s.bz2"' % templateFile)
shutil.copy(templateFile, 'imaging.dmg')
shutil.copy(templateFile, 'imaging.sparseimage')
remkdir('imaging')
os.system('hdiutil attach imaging.dmg -noautoopen -quiet -mountpoint imaging')
os.system('hdiutil attach imaging.sparseimage -noautoopen -quiet -mountpoint imaging')
shutil.rmtree('imaging/Doomsday Engine.app', True)
remove('imaging/Read Me.rtf')
duptree('Doomsday Engine.app', 'imaging/Doomsday Engine.app')
Expand All @@ -214,8 +214,8 @@ def mac_release():
' "' + "Doomsday Engine " + DOOMSDAY_VERSION_FULL + '"')

os.system('hdiutil detach -quiet imaging')
os.system('hdiutil convert imaging.dmg -format UDZO -imagekey zlib-level=9 -o "' + target + '"')
remove('imaging.dmg')
os.system('hdiutil convert imaging.sparseimage -format UDZO -imagekey zlib-level=9 -o "' + target + '"')
remove('imaging.sparseimage')


def win_release():
Expand Down
2 changes: 2 additions & 0 deletions snowberry/template-image/.gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
template.dmg
template.sparseimage

Binary file removed snowberry/template-image/template.dmg.bz2
Binary file not shown.
Binary file not shown.

0 comments on commit 9474c8f

Please sign in to comment.