DA for Mac C
Volume Number: 2
Issue Number: 4
Column Tag: C Workshop
A DA for Mac C without Desk Maker 
By Don Melton, Staff Artist, Orange County Register
Write your Mac C DA's Direct!
There's a definite problem in developing desk accessories with the Consulair Mac
C environment: DeskMaker!
DAs are difficult enough to write without having to spend your time with a
flaky-pseudo-second-linker to create a Font/DA Mover compatible file. While most
development systems provide compiler and/or linker options to create DAs, Mac C
must rely on DeskMaker.
For those of you using assembler, Pascal or perhaps another brand of C, let me
explain. After you compile and link a Mac C program that is to become a desk
accessory, you must run DeskMaker. Using a standard file dialog, DeskMaker asks you
for the name of a desk control file. This file is a bit like a linker directive, but it
specifies such things as the DA name, the map file name from the linker, ID, flags and
other such stuff. After much disk access a DA is created.
This works but DeskMaker will not function correctly with the Exec, it gets
confused about source and destination volumes (worse than RMaker), it does not filter
TEXT file names in its standard file dialog, you have to create yet another directive
(aren't link and job files bad enough?), and it's one more step to slow down
development!
Mac C is a very good development system, and Consulair is constantly upgrading
and improving their compiler and linker/librarian. They even recently released a disk
full of useful development utilities. But as of this writing, they have not updated or
improved DeskMaker.
I knew there was probably an easier way to develop DAs in Mac C, so in January
of 1986, I started working on the problem. On the following pages I'll show you my
alternative to DeskMaker and how I developed it. Plus, I'll take you step by step
through the source code of a real desk accessory to show you valuable techniques I