Al, the best way, IMHO, is to set up, in Lazarus, multiple modes. Then you have a mode for windows and it automatically uses the Windows widget set, similarly for Mac, it uses Cocoa. That mode data is stored in the lpi file and you can, if you like, use it to build from Lazarus or the command line driven Lazbuild, later being easier for automated build systems.
You can have modes for every target, with and without debugging for example. Makes life a lot easier once setup.
In your code you will have some eg
{$ifdef UNIX}A := blah{$endif}
{$ifdef WINDOWS}A := blar{$endif}
StartServer({$ifdef WINDOWS}False{$else}True{$endif});
'UNIX' is perhaps better than using DARWIN, it will cover many of the tests you want to use, and will let you build a Linux version as well. But you will certainly need a few more explicit ones, {$IFDEF DARWIN}.
There are a range of those directives, {$else ...} etc.
Davo