[CDG5] Random questions
Elliot Nunn
elliotnunn at fastmail.com
Thu Dec 13 17:21:53 AWST 2018
Oops! I got that one backwards. My 9.2.2 System file has plenty of
Huffmanesque resources now that I have a look at it.
Max, I'm thinking about how to package macresources, now that my
'compression' branch is mature enough to round-trip everything I throw
at it. In particular, it handles the 'missing algorithm' case elegantly,
so we can add algorithms at will. There are a few ways to call your code
from my PyPI package (you'll see a pull request on GitHub with some API
changes):
1. Package your own on PyPI so I can declare it as a dependency.
2. Merge it Git-wise into my repo, and then I merge your commits as I
go.
3. Merge it as above, but then do future development in the macresources
repo.
I favour option 3 as the most natural way. ResDecompress will be
exported as a subpackage (maybe with a lowercase name). Happy with the
MIT license on macresources?
> On 13 Dec 2018, at 7:44 am, Jason Duerstock <jason.duerstock at gmail.com> wrote:
>
> There's only a 68k implementation (dcmp.0003), no ppc implementation.
> On Wed, Dec 12, 2018 at 10:03 AM Elliot Nunn <elliotnunn at fastmail.com> wrote:
>>
>> Huh... that’s surprising news about your System file. Given the largely transparent nature of this compression scheme, it is possible to imagine accidental expansion occurring somewhere in the build, localisation, installation or update process. But I don’t know.
>>
>> Good call on the Huffman code. Any chance it could be a well known algo? Is there a 68k implementation?
>>
>> On 12 Dec 2018, at 5:35 pm, Max Poliakovski <maximumspatium at googlemail.com> wrote:
>>
>> Elliot,
>>
>>> Grepping through System 9.2.2 reveals several compressed resources:
>>>
>>> Could you have used a search method that extracted the resources
>>> automatically?
>>
>>
>> No. I opened the resource fork in a Unix Hexeditor and searched for 0xA89F6572.
>> According to ResEdit, both CDEF #62 and DRVR #2 are uncompressed in my german "System" file: the "compressed" checkbox isn't selected.
>> Does ResEdit unpack resources in background when opening a file for edit?
>>
>> $ SimpleDeRez ~/System/..namedfork/rsrc -compcmt -ascii | grep -A3 _compressed | head -n9
>> data 'CDEF' (62, $61 /*sysheap, purgeable, _compressed*/) {
>> $"A89F 6572 0012 0901 0000 0454 0003 03FF" /* ..er.......T.... */
>> $"0000 3F04 E56F FF44 8E70 7082 A2E0 0083" /* ..?..o.D.pp..... */
>> $"E2E0 0122 86E0 00E7 C0A2 0544 3EEF FF85" /* ...".......D>... */
>> --
>> data 'DRVR' (2, ".Print", $71 /*sysheap, purgeable, locked, _compressed*/) {
>> $"A89F 6572 0012 0901 0000 019A 0003 03FF" /* ..er............ */
>> $"0000 2278 058F FC90 00A0 00B0 00C0 00D0" /* .."x............ */
>> $"18B9 41C9 A5B9 D080 0001 1149 5948 0008" /* ..A........IYH.. */
>>
>>>
>>> Here are some Donn resources, both compressed and extracted (manual
>>> operation... ugh!). How will I identify the mysterious Mac OS 9 format?
>>
>>
>> CDEF #62:
>> $"A89F 6572 0012 0901 0000 0454 0003 03FF"
>> DRVR #2:
>> $"A89F 6572 0012 0901 0000 019A 0003 03FF"
>>
>> According to the defconID = 0x0003, both resources are compressed with that mysterious new method.
>>
>> A short peek into 'dcmp' #3 reveals a sophisticated compression method utilizing Huffman coding. It contains neither strings nor tables. Just a lot of code, much larger than Donn&Gregg stuff. I therefore suggest to postpone its RE until the Trampoline work is finished...
>>
>> BTW, many thanks for the Donn bits! I'll analyze them soon...
>>
>> _______________________________________________
>> cdg5 mailing list
>> cdg5 at ucc.asn.au
>> https://lists.ucc.gu.uwa.edu.au/mailman/listinfo/cdg5
>>
>> _______________________________________________
>> cdg5 mailing list
>> cdg5 at ucc.asn.au
>> https://lists.ucc.gu.uwa.edu.au/mailman/listinfo/cdg5
> _______________________________________________
> cdg5 mailing list
> cdg5 at ucc.asn.au
> https://lists.ucc.gu.uwa.edu.au/mailman/listinfo/cdg5
More information about the cdg5
mailing list