[REQUEST] Self running image for Unix type OS's

Ian Piumarta Ian.Piumarta at inria.fr
Tue Oct 26 15:27:32 UTC 1999


Lex,

> But don't you need to modify the image *reader*, too?

Nope.  Errrr, at least I don't think so...

Check the method comment in #readImageFromFile:HeapSize:StartingAt:
(you weren't paying attention earlier, were you? ;-) and for the
details the implementation of #checkImageVersionFrom:startingAt:.
This method checks twice for a valid header, once at offset 0 and
again at offset 512.  (I implemented it like that because images
transferred from Mac to Unix often had what looked like the resource
fork prepended to the data.)  The only way it could break is if the
image version number (currently 6502 -- another left-over from
Smalltalk-76 running on 8-bit micros perhaps? ;-) ever reaches
572617585 (or 1903370530).

> Ideally, one could save a unix-ified image and still have it
> readable by other VM's, too.

I didn't try it, but only because I was convinced it would work.  (If
you have evidence to the contrary then life itself is in contempt of
court for being neither beautiful nor true. ;-)

Regards,

Ian





More information about the Squeak-dev mailing list