4 ms·
I’ve been doing some dives into Mac 68K programming recently, and ran into the same question—what about color on System 6? Like the author, I don’t have a Mac w
by dietrichepp 3y ago
I’ve been doing some dives into Mac 68K programming recently, and ran into the same question—what about color on System 6? Like the author, I don’t have a Mac which is both color and runs System 6.
The old Inside Macintosh volumes are sometimes difficult to follow. New features got added to newer system software versions, and new features got added to newer ROM versions, and if you want to support older Macs, then you sometimes have to search through the volumes until you find when a particular feature was introduced. (The original Inside Macintosh volumes are organized in chronological order, corresponding to major ROM or system software updates.) If you just look at the description of one of the functions in the OS or toolbox, there’s no mention of when it was introduced.
I also discovered that despite my efforts to make a program compatible with the Mac 128K and 512K, my programs won’t run on those systems. The 128K and 512K have the very first ROM version, with the 64K ROMs, and I suspect that the application startup code which ships with CodeWarrior checks for a 64K ROM and aborts the program. So even if I’m careful to only use functions that are available in the 64K ROM, my program won’t run on a 64K ROM unless I use a different toolchain or rewrite the startup code.
- azalemeth 3y agoNaïve question: what's wrong with quemu and this emulation target?
- duskwuff 3y agoqemu only supports one 68k Macintosh machine target (the Quadra 800), which is too new to run System 6.
- Someone 3y agoCheck whether your code gets called by writing a main that doesn’t use any traps but just loops clearing the screen, fills it with black, clears it, etc. If it doesn’t get called, disassemble the startup code. It can’t be long. I would use a version of ResEdit that has a built-in disassembler (advantage: you won’t have to run that on a 512k Mac, but can use a beefier one or an emulator) You also may want to use the earliest version of CodeWarrior you can find, as support for System 6 may have stopped at some time.
- dietrichepp 3y agoCodeWarrior ships with the source code for the startup code, but it is unfortunately somewhat long.
- Palomides 3y agoI've heard later versions of codewarrior had crappier 68k support, not due to strictly deprecating it, but just lack of interest/maintenance work as the OS developed and PPC happened
- anthk 3y agoCheck jcs's site. He writes unix/openbsd related code but it has a section on System6 programming. https://jcs.org/system6c https://jcs.org/system6c Also, telnet to klud [DOT] ge to test his BBS hosted in a System 6 machine.
- jamesfmilne 3y agoTo target stuff that old I'd try MPW. I used to use Codewarrior back in the day, but these days I prefer MPW, as its more like developing on modern macOS/Linux.
- dietrichepp 3y agoThat’s a good suggestion—I decided not to use MPW because the CodeWarrior compilers are better, the CodeWarrior UX is better, etc. For now, I’d rather drop 128K support and keep using CodeWarrior. The binaries work just fine on Macs with the 128K ROM (like the Mac Plus), and there are a number of additional difficulties you face when developing for 64K ROMs. Some of the other difficulties—no MaxApplZone, the segment manager behaves differently, and if you really want Mac 128K support, you have to copy to an MFS formatted disk. Some versions of the OS ship with broken MFS implementations, presumably because nobody cared whether it worked. I suspect that the segment manager behavior is a particularly thorny issue because it affects the location of code segments in memory, and you have to be careful when you only have 128K.
- canucker2016 3y agoTHINK C was great back then, before Symantec got their fingers into it. v2.x - v4 were released around System 6-7 timeframe.