MacRelix runtime packaging and MacRelix installer coming soon

139 views
Skip to first unread message

Josh Juran

unread,
Sep 26, 2012, 5:09:07 AM9/26/12
to classic...@googlegroups.com
I've extended MacRelix's virtual filesystem code to recognize
binaries and scripts embedded in the MacRelix application's resource
fork. (Non-executable files aren't supported yet, but that's an easy
addition.) This makes it possible to package a partial installation
of MacRelix as a single file.

This enables the 'runtime' use case, in which you write an
application using FORGE and use a custom MacRelix startup script to
run it. (Actually, you already can do this, but now it wouldn't have
the Unix directory structure implementation detail exposed.)

http://www.metamage.com/code/MacRelix/
http://www.metamage.com/code/forge/

FORGE: Hello World
http://www.youtube.com/watch?v=JgivHy-oC2g

The first non-trivial runtime I'm going to create is an installer for
MacRelix. As a single file, it can be packaged using plain
MacBinary, so file download agents will be able to unpack it
properly. It will include just enough of MacRelix's userspace to
download and expand the full MacRelix archive.

Expect to see this in a few days or so.

Josh


Cameron Kaiser

unread,
Sep 26, 2012, 9:39:10 AM9/26/12
to classic...@googlegroups.com
> I've extended MacRelix's virtual filesystem code to recognize
> binaries and scripts embedded in the MacRelix application's resource
> fork. (Non-executable files aren't supported yet, but that's an easy
> addition.) This makes it possible to package a partial installation
> of MacRelix as a single file.

When I get my MDD's power supply fixed, I'll have to give this a try.

--
------------------------------------ personal: http://www.cameronkaiser.com/ --
Cameron Kaiser * Floodgap Systems * www.floodgap.com * cka...@floodgap.com
-- I know you're out there, Eh!Steve! -----------------------------------------

Matt Lewandowsky

unread,
Sep 26, 2012, 9:50:38 AM9/26/12
to Josh Juran, classic...@googlegroups.com
Most awesome! I should have time to poke at MacRelix again next week, and that changes a bit what I can do with it. :)

--Matt
Sent on the Sprint® Now Network from my BlackBerry®

-----Original Message-----
From: Josh Juran <jju...@gmail.com>
Date: Wed, 26 Sep 2012 09:09:07
To: <classic...@googlegroups.com>
Subject: MacRelix runtime packaging and MacRelix installer coming soon

I've extended MacRelix's virtual filesystem code to recognize 
binaries and scripts embedded in the MacRelix application's resource 
fork.  (Non-executable files aren't supported yet, but that's an easy 
addition.)  This makes it possible to package a partial installation 
of MacRelix as a single file.

This enables the 'runtime' use case, in which you write an 

Josh Juran

unread,
Sep 28, 2012, 9:04:02 PM9/28/12
to Josh Juran, classic...@googlegroups.com
On Sep 26, 2012, at 2:09 AM, Josh Juran wrote:

> I've extended MacRelix's virtual filesystem code to recognize
> binaries and scripts embedded in the MacRelix application's
> resource fork.
>
> Expect to see this in a few days or so.

The latest MacRelix snapshot has this. Also, resource filenames
(e.g. foo.rsrc/r/0080.TEXT) no longer contain the resource name.
Instead, the resource name is modeled as "$resource/name",
analogously to "$file/rsrc" for the resource fork.

Reading "name" appends a newline, and writing it will strip one (or
fail if it's missing), for compatibility with cat and echo from the
shell. The variant ".~name" will be a pure binary file but hasn't
been added yet. A known error is that UTF-8 text written to a
resource name file is not converted to MacRoman (nor the reverse), I
will fix this soon, and also ".mac-name" and ".~mac-name" which will
not convert character encodings, on the assumption that you're
supplying and expecting MacRoman directly.

exe=""
test "$HOSTTYPE" == m68k && exe=/r/0000.Wish

cp /sys/app/dir/MacRelix /tmp
cd /tmp/MacRelix/r
cat /bin/cat$exe > 0080.Exec
echo /bin/cat > 0080.Exec/name
...
cat /bin/true$exe > 009F.Exec
echo /bin/true > 009F.Exec/name

Share and enjoy!

Josh


Josh Juran

unread,
Oct 1, 2012, 4:27:42 AM10/1/12
to Josh Juran, classic...@googlegroups.com
On Sep 28, 2012, at 6:04 PM, Josh Juran wrote:

> On Sep 26, 2012, at 2:09 AM, Josh Juran wrote:
>
>> I've extended MacRelix's virtual filesystem code to recognize
>> binaries and scripts embedded in the MacRelix application's
>> resource fork.
>>
>> Expect to see this in a few days or so.
>
> The latest MacRelix snapshot has this. Also, resource filenames
> (e.g. foo.rsrc/r/0080.TEXT) no longer contain the resource name.
> Instead, the resource name is modeled as "$resource/name",
> analogously to "$file/rsrc" for the resource fork.
>
> Reading "name" appends a newline, and writing it will strip one (or
> fail if it's missing), for compatibility with cat and echo from the
> shell. The variant ".~name" will be a pure binary file but hasn't
> been added yet. A known error is that UTF-8 text written to a
> resource name file is not converted to MacRoman (nor the reverse),
> I will fix this soon, and also ".mac-name" and ".~mac-name" which
> will not convert character encodings, on the assumption that you're
> supplying and expecting MacRoman directly.

This is now done.

Also, the latest MacRelix (20120930-1025) will use its own parent
directory as root if the "/" folder doesn't exist. The only issue is
that /sys/app/dir/ resolves to the root directory, so /sys/app/dir/..
does also, which affects the current upgrade script -- it downloads
to the root directory instead of its HFS parent. Once I work around
this, MacRelix will be ready for a simple 'upgrade' wrapper called
'installer'.

Josh


Josh Juran

unread,
Oct 1, 2012, 5:16:47 PM10/1/12
to classic...@googlegroups.com
On Sep 26, 2012, at 6:39 AM, Cameron Kaiser wrote:

>> I've extended MacRelix's virtual filesystem code to recognize
>> binaries and scripts embedded in the MacRelix application's resource
>> fork. (Non-executable files aren't supported yet, but that's an easy
>> addition.) This makes it possible to package a partial installation
>> of MacRelix as a single file.
>
> When I get my MDD's power supply fixed, I'll have to give this a try.

Have you given any thought to funding some of MacRelix's
development? :-)

Josh


Cameron Kaiser

unread,
Oct 1, 2012, 9:28:36 PM10/1/12
to classic...@googlegroups.com
> >> I've extended MacRelix's virtual filesystem code to recognize
> >> binaries and scripts embedded in the MacRelix application's resource
> >> fork. (Non-executable files aren't supported yet, but that's an easy
> >> addition.) This makes it possible to package a partial installation
> >> of MacRelix as a single file.
> >
> > When I get my MDD's power supply fixed, I'll have to give this a try.
>
> Have you given any thought to funding some of MacRelix's
> development? :-)

After I fund getting more power supplies ;)

--
------------------------------------ personal: http://www.cameronkaiser.com/ --
Cameron Kaiser * Floodgap Systems * www.floodgap.com * cka...@floodgap.com
-- Rational behavior is a choice, not a predestination. -- Kent Paul Dolan ----

laus...@gmail.com

unread,
May 18, 2015, 11:59:29 AM5/18/15
to classic...@googlegroups.com, jju...@metamage.com
понедельник, 1 октября 2012 г., 11:27:42 UTC+3 пользователь Josh написал:
Once I work around  
this, MacRelix will be ready for a simple 'upgrade' wrapper called  
'installer'.

Josh

Hi, Josh.

Could you please add a platform detection to your MacRelix installer, so it will pick os9 release on a Mac OS 9 PPC platform? Currently it picks 68k version both on my mac os 9 computer and on my friend's mac os 9 machine.

Also I would be much thankful if you could write on how to use codewarrior compiler from the MacRelix. Full question is here: https://groups.google.com/forum/#!topic/classic-mac-dev/yK5mwO47WEk 

Josh Juran

unread,
May 18, 2015, 12:22:02 PM5/18/15
to classic...@googlegroups.com
On May 18, 2015, at 8:59 AM, laus...@gmail.com wrote:

> Could you please add a platform detection to your MacRelix installer, so it will pick os9 release on a Mac OS 9 PPC platform? Currently it picks 68k version both on my mac os 9 computer and on my friend's mac os 9 machine.

Sure, I can do that.

> Also I would be much thankful if you could write on how to use codewarrior compiler from the MacRelix. Full question is here: https://groups.google.com/forum/#!topic/classic-mac-dev/yK5mwO47WEk

As I said, it's complicated...

Josh

Josh Juran

unread,
Jun 1, 2015, 4:58:56 AM6/1/15
to classic...@googlegroups.com
On May 18, 2015, at 9:21 AM, Josh Juran <jju...@gmail.com> wrote:

> On May 18, 2015, at 8:59 AM, laus...@gmail.com wrote:
>
>> Could you please add a platform detection to your MacRelix installer, so it will pick os9 release on a Mac OS 9 PPC platform? Currently it picks 68k version both on my mac os 9 computer and on my friend's mac os 9 machine.
>
> Sure, I can do that.

Okay, this is now done. The installer script will determine whether Mac OS is running natively in 68K or PPC or in Classic, and choose a variant of MacRelix accordingly.

Josh

Reply all
Reply to author
Forward
0 new messages