Common makefile (gasp) stuff

Walter Bright via Digitalmars-d digitalmars-d at puremagic.com
Tue Jan 13 20:49:36 PST 2015


On 1/13/2015 3:20 PM, Andrei Alexandrescu wrote:
> Over the time a number of stuff has become quite duplicated across our makefiles
> for dmd, druntime, and phobos.
>
> These include fetching OS and model but (newer) general-purpose macros for e.g.
> rebasing repos, see
> https://github.com/D-Programming-Language/dlang.org/blob/master/posix.mak#L37.
>
> I think it's time to reduce clutter and duplication by migrating such common
> stuff into one common.mak file. Question is, where should that file sit? One
> candidate is tools/ but it's not really a tool. Another candidate is dmd/src/
> because that would be the first thing anyone depends on.
>
> Ideas?


It's a few lines of duplication, as opposed to adding another point of failure 
to the build process, i.e. common.mak isn't found or the wrong one is found, etc.

I've always tended to avoid using make macro include's for this reason.


More information about the Digitalmars-d mailing list