VirtualBox

Changeset 105340 in vbox for trunk/src/VBox/Installer/darwin


Ignore:
Timestamp:
Jul 16, 2024 9:12:33 AM (5 months ago)
Author:
vboxsync
Message:

Installer/darwin: Added new kmk build targets 'mount_dmg' and 'unmount_dmg' to the Makefile which make modifying / updating the embedded .DS_Store file of the .dmg installer a lot easier. See Makefile for details. bugref:10724

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Installer/darwin/Makefile.kmk

    r104826 r105340  
    10751075VirtualBox.mpkg: $(VBOX_PATH_PACK_TMP)/DiskImage/VirtualBox.pkg
    10761076VirtualBox.dmg: $(VBOX_PATH_DIST)/VirtualBox-$(VBOX_VERSION_STRING)-r$(VBOX_SVN_REV).dmg
     1077
     1078# Path specifying the .dmg mount point being used with 'kmk mount_dmg' and 'kmk unmount_dmg'.
     1079VBOX_PATH_DMG_MOUNTPOINT := /Volumes/VirtualBox-$(VBOX_VERSION_STRING)-r$(VBOX_SVN_REV)
     1080
     1081#
     1082# Mounts the created .dmg file within Finder in read-write mode using a shadow storage
     1083# which holds the modififed content.
     1084#
     1085# This is needed in order to modify the styling of the .dmg's DS_Store file (which is a
     1086# proprietary file format known by Finder). Needs root.
     1087#
     1088mount_dmg:
     1089        @kmk_builtin_echo "Mounting .dmg file in R/W mode (using shadow storage) ..."
     1090        @sudo hdiutil attach -quiet -readwrite \
     1091                -mountpoint $(VBOX_PATH_DMG_MOUNTPOINT) \
     1092                -shadow $(VBOX_PATH_DIST)/VirtualBox-$(VBOX_VERSION_STRING)-r$(VBOX_SVN_REV)-shadow.dmg \
     1093                $(VBOX_PATH_DIST)/VirtualBox-$(VBOX_VERSION_STRING)-r$(VBOX_SVN_REV).dmg
     1094        @kmk_builtin_echo ""
     1095        @kmk_builtin_echo "Successfully mounted within Finder."
     1096        @kmk_builtin_echo "You may now alter the .dmg image as needed. To save your changes, unmount via 'kmk unmount'."
     1097
     1098#
     1099# Unmounts the formerly mounted .dmg file and saves the (eventually) altered .DS_Store file from the
     1100# shadow storage back into the SVN repo tree. Needs root.
     1101#
     1102unmount_dmg:
     1103        @kmk_builtin_echo "Unmounting .dmg file ..."
     1104        @kmk_cp $(VBOX_PATH_DMG_MOUNTPOINT)/.DS_Store $(PATH_SUB_CURRENT)/DiskImage/DS_Store
     1105        @sudo hdiutil detach -quiet $(VBOX_PATH_DMG_MOUNTPOINT)
     1106        @kmk_builtin_echo "Files have been updated within SVN tree. Check what the changes are."
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette