OS X Installer

Walter Bright newshound1 at digitalmars.com
Thu Jul 23 12:22:02 PDT 2009


Jarrett Billingsley wrote:
> Yeah, let me know when that happens.  Until then, I'd like to continue
> to be able to use my build tools that were designed for D1 without
> having to modify all their config files.

I don't know what build tools you're using, but consider make:

------ win32.mak ---------

DMD=\dmd\windows\bin\dmd

target : foo.obj

foo.obj : foo.d
     $(DMD) -c foo
--------------------------

Now, we can drive it with a makefile that customizes the macros like so:

------ makefile ----------

target:
     make -fwin32.mak DMD=\dmd2\windows\bin\dmd
--------------------------


I use this technique a lot. You can also have makefiles recursively call 
themselves and reset the macros:

---------- makefile --------
DMD=\dmd\windows\bin\dmd

target : foo.obj

target2:
     make target DMD=\dmd2\windows\bin\dmd

foo.obj : foo.d
     $(DMD) -c foo
----------------------------



More information about the Digitalmars-d mailing list