help-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to capture a set of recurring rules?


From: Philip Guenther
Subject: Re: How to capture a set of recurring rules?
Date: Fri, 5 Feb 2010 20:25:18 -0800

On Fri, Feb 5, 2010 at 9:07 AM, Peng Yu <address@hidden> wrote:
...
> Essentially, what you are saying is to create an embedded language in
> GNU make to make it more powerful. Since this embedded language is not
> supported natively by GNU make, will the code written in this embedded
> language be difficult to debugging?

IMO, that's the wrong question.  The right question is whether it will
be more difficult to write and debug that set of makefiles than an
equivalent set written directly.  If yes then they are a net gain.  If
not, then that embedded language gets discarded.


> A similar situation arises in C++ template metaprogramming. Although
> you can do a lot of complex things in template, but it makes the
> debugging process more difficult unless there are appropriate
> debugging tools.

I think that's because the C++ metaprogamming 'language' is so far
from C++ itself.  In lisp, the metaprogramming language is lisp
itself.  I would say GNU make is some where in between: not nearly the
indirect freak that is C++ but not the completely regular world of
lisp.


> Considering these things, I think that a better route in the long run
> may be to consider what is features are essential and add the features
> along with the debugging facilities.

Sure, which is where $(call) and $(eval) and $(value) came from.
People who faced these problems over and over again came up with those
to solve their problems.

On the other hand, other people said "forget the make syntax, I want
something more regular" and created other build tools.  Have you taken
a look at them?  (If not, consider why not and what that says about
the priorities of your requirements for a build tool.)


Philip Guenther




reply via email to

[Prev in Thread] Current Thread [Next in Thread]