Difference between revisions of "Mount dmg"

From gr0x0rd
Jump to navigation Jump to search
(Created page with "To do this we'll use a masked package: dmg2img. You'll need to unmask it using /etc/portage/package.keywords. Apparently this package is the successor of dmg2iso. The syntax ap...")
 
 
Line 13: Line 13:
 
  Device Drivers  --->
 
  Device Drivers  --->
 
   [*] Block devices  --->
 
   [*] Block devices  --->
   <*>  Loopback device support[/code]
+
   <*>  Loopback device support
  
 
Once you have these prereqs, you can mount the img file.
 
Once you have these prereqs, you can mount the img file.
 
  mkdir ihatemac
 
  mkdir ihatemac
 
  sudo mount -t hfsplus -o loop stupidmacfile.img ihatemac
 
  sudo mount -t hfsplus -o loop stupidmacfile.img ihatemac

Latest revision as of 10:52, 9 June 2011

To do this we'll use a masked package: dmg2img. You'll need to unmask it using /etc/portage/package.keywords.

Apparently this package is the successor of dmg2iso. The syntax appeared to be fairly simple, but it installed to /usr/sbin so you need to be root to use it. In the example below, substitute stevejobsiswaistingmytime.dmg with the name of your .dmg file and stupidmacfile.img with your desired img file name. There are some switches so feel free to look at these for yourself.

sudo dmg2img [opts] stevejobsiswaistingmytime.dmg stupidmacfile.img

This converts the (compressed?) dmg file to an img file in hfs format.

To mount this image, you'll need support for hfs and loopback devices in your kernel.

File systems  ---> 
 [*] Miscellaneous filesystems  --->
  <*>   Apple Macintosh file system support (EXPERIMENTAL)
  <*>   Apple Extended HFS file system support 

Device Drivers  --->
 [*] Block devices  --->
  <*>   Loopback device support

Once you have these prereqs, you can mount the img file.

mkdir ihatemac
sudo mount -t hfsplus -o loop stupidmacfile.img ihatemac