From: Orena Radrax on
Hi,
I'm desperately trying to migrate a Mac OS X installer to a smaller
system. The current installer is very basic: it is a Mac OS X system
that boots on an external drive and run a script that creates 3
partitions on the local disk, then restore DMGs on them, and finally set
the boot flag to the correct partition.
Technically, it is hdiutil (or diskutil) to create the partitions, asr
to restore DGMs, and bless to take care of the boot.

On of the DMGs is also a full Mac OS X system. The result is a very
heavy installer (even if we removed most of the useless stuffs).

I can build a very light FreeBSD system (using m0n0wall or FreeNAS
projects) but I will need HFS+ support.

I successfully compiled gpt fdisk to create partitions on a GPT drive.
Now I have to create the filesystem and manage the DMGs. I saw that
hfsutils can handle them, or they can be converted to IMGs. But I am not
able to find a suitable tool to create an HFS+ filesystem (even non
journaled).

GEOM_APPLE has been removed. The hfs port is ultra deprecated. Linux has
a lot of working tools to handle HFS+ (read and write on non-journaled).
There are also source codes from Apple. But I can't find anything for
FreeBSD.

Does anyone have a clue?
From: Indi on
On 2010-07-21, Orena Radrax <radrax(a)astraweb.com> wrote:
> Hi,
> I'm desperately trying to migrate a Mac OS X installer to a smaller
> system. The current installer is very basic: it is a Mac OS X system
> that boots on an external drive and run a script that creates 3
> partitions on the local disk, then restore DMGs on them, and finally set
> the boot flag to the correct partition.
> Technically, it is hdiutil (or diskutil) to create the partitions, asr
> to restore DGMs, and bless to take care of the boot.
>
> On of the DMGs is also a full Mac OS X system. The result is a very
> heavy installer (even if we removed most of the useless stuffs).
>
> I can build a very light FreeBSD system (using m0n0wall or FreeNAS
> projects) but I will need HFS+ support.
>
> I successfully compiled gpt fdisk to create partitions on a GPT drive.
> Now I have to create the filesystem and manage the DMGs. I saw that
> hfsutils can handle them, or they can be converted to IMGs. But I am not
> able to find a suitable tool to create an HFS+ filesystem (even non
> journaled).
>
> GEOM_APPLE has been removed. The hfs port is ultra deprecated. Linux has
> a lot of working tools to handle HFS+ (read and write on non-journaled).
> There are also source codes from Apple. But I can't find anything for
> FreeBSD.
>
> Does anyone have a clue?

I believe GEOM_APPLE was replaced with GEOM_APM (Apple Partition Map)
and GEOM_GPT. However I have never been able to get HFS+ support to
work at all in FreeBSD.

--
Caveat utilitor,
indi

From: Orena Radrax on
On 22/07/10 18:26, Indi wrote:
> On 2010-07-21, Orena Radrax wrote:
>> Hi,
>> I'm desperately trying to migrate a Mac OS X installer to a smaller
>> system. The current installer is very basic: it is a Mac OS X system
>> that boots on an external drive and run a script that creates 3
>> partitions on the local disk, then restore DMGs on them, and finally set
>> the boot flag to the correct partition.
>> Technically, it is hdiutil (or diskutil) to create the partitions, asr
>> to restore DGMs, and bless to take care of the boot.
>>
>> On of the DMGs is also a full Mac OS X system. The result is a very
>> heavy installer (even if we removed most of the useless stuffs).
>>
>> I can build a very light FreeBSD system (using m0n0wall or FreeNAS
>> projects) but I will need HFS+ support.
>>
>> I successfully compiled gpt fdisk to create partitions on a GPT drive.
>> Now I have to create the filesystem and manage the DMGs. I saw that
>> hfsutils can handle them, or they can be converted to IMGs. But I am not
>> able to find a suitable tool to create an HFS+ filesystem (even non
>> journaled).
>>
>> GEOM_APPLE has been removed. The hfs port is ultra deprecated. Linux has
>> a lot of working tools to handle HFS+ (read and write on non-journaled).
>> There are also source codes from Apple. But I can't find anything for
>> FreeBSD.
>>
>> Does anyone have a clue?
>
> I believe GEOM_APPLE was replaced with GEOM_APM (Apple Partition Map)
> and GEOM_GPT. However I have never been able to get HFS+ support to
> work at all in FreeBSD.
>

Thanks for the information. For now, I have tried to create the GPT
structure and restore a dmg with Linux. Gdisk and sgdisk work fine on
Linux. I was able to get the content of the dmg by first converting it
to img (I don't know why I can't mount the dmg directly). So far so good
until I realize:
- I will have troubles with the boot (maybe rEFIt can do the trick?)
- The Linux HFS+ support doesn't manage resource and data forks. That's
a bad news when you want to copy a Snow Leopard system. Linux can't read
the compressed files (just like Leopard can't).

I think my best bet is PureDarwin. HFS+ is definitely for Mac only :/
From: Indi on
On 2010-07-22, Orena Radrax <radrax(a)astraweb.com> wrote:
>
> Thanks for the information. For now, I have tried to create the GPT
> structure and restore a dmg with Linux. Gdisk and sgdisk work fine on
> Linux. I was able to get the content of the dmg by first converting it
> to img (I don't know why I can't mount the dmg directly). So far so good
> until I realize:
> - I will have troubles with the boot (maybe rEFIt can do the trick?)
> - The Linux HFS+ support doesn't manage resource and data forks. That's
> a bad news when you want to copy a Snow Leopard system. Linux can't read
> the compressed files (just like Leopard can't).
>
> I think my best bet is PureDarwin. HFS+ is definitely for Mac only :/

Interesting. I notice the PureDarwin site has been without an update
since January, which is a bit sad.

Why are you building your own OS X installer?

--
Caveat utilitor,
indi