Have Win DMD use gmake instead of a separate DMMake makefile?

Jonathan M Davis jmdavisProg at gmx.com
Sat Aug 10 17:23:08 PDT 2013


On Saturday, August 10, 2013 17:14:35 H. S. Teoh wrote:
> On Sat, Aug 10, 2013 at 04:21:45PM -0700, Jonathan M Davis wrote:
> > On Saturday, August 10, 2013 14:35:04 Nick Sabalausky wrote:
> > > Is this something that would be acceptable, or does building DMD for
> > > Windows need to stay as DM make?
> > 
> > I don't see any problem with it, but that doesn't mean that Walter
> > won't.
> > 
> > Another suggestion that I kind of liked was to just build them all
> > with a single script written in D and ditch make entirely, which would
> > seriously reduce the amount of duplication across platforms. But
> > that's obviously a much bigger change and would likely be much more
> > controversial than simply using a more standard make.
> 
> [...]
> 
> I'm all for ditching make.  What about this:
> 
> - We write a small D app that automatically scans all dependencies and
>   generates a shell script / .BAT file / whatever the target platform
>   uses, that contains compile commands that builds DMD and a make
>   replacement written in D. This is for bootstrapping.
> 
> - The make replacement written in D can then be used to rebuild DMD,
>   build druntime, Phobos, etc..
> 
> The first step is what makes this all work, 'cos you'll need to already
> have a working D compiler before step 2 is usable. (Either that, or ship
> binaries, but then you'll get people complaining about their platform of
> choice not being supported, the binaries being incompatible with their
> quirky installation of system libraries, etc..) Once DMD is built, we
> can junk the script / .BAT file and use the D make-replacement from then
> on.

Since we're going to be porting dmd to D, which will force you to have a D 
compiler to build the D compiler anyway, I don't see any reason to jump 
through hoops to make anything bootstrappable. In the long run, you're going 
to have to either start with a dmd which compiled with C++ or cross-compile it 
from a machine which already has dmd, which is exactly the same boat that 
C/C++ are in. It's just that they've been around a lot longer, are supported 
on more platforms, and don't change as much.

- Jonathan M Davis


More information about the Digitalmars-d mailing list