Subject: Darwin HFS+ workaround
To: None <>
From: Amitai Schlair <>
List: tech-pkg
Date: 03/29/2002 01:59:03
A while back we discussed how Darwin's default filesystem (HFS+) is
case-insensitive and gives pkgsrc several kinds of trouble. The general
consensus was to use UFS. However, this is often hard to do: common
configurations don't have spare disk partitions, and Darwin's disk image
tools are really weird.

After much trial and error, I've written a script which hides the weirdness
and makes dealing with UFS disk images fairly simple:

$ ftp
$ for i in format mount umount; do ln dmg_create dmg_${i}; done
$ chmod +x dmg_*
$ ./dmg_create ufsdisk.dmg 1024    # megabytes
$ ./dmg_format ufsdisk.dmg
$ ./dmg_mount ufsdisk.dmg /path/to/mount/point
$ ./dmg_umount /path/to/mount/point

If this helps people, perhaps it can go into the next Darwin bootstrap kit.
Ultimately I'd like to see the bootstrap do something excessively helpful,
such as offer to create and mount a UFS image if there isn't already a UFS
partition mounted. :-)

- Amitai