Re: [dev] Reasonable Makefiles

From: sin <>
Date: Tue, 11 Feb 2014 13:28:42 +0000

On Tue, Feb 11, 2014 at 01:28:25PM +0100, Markus Teich wrote:
> Nick wrote:
> > I was reading the opengroup specifications for make(1) recently[0],
> > and found that even our standard makefile practise of using 'include'
> > for config variables is nonstandard, as far as they're concerned.
> > Needless to say I think 'include' is a perfectly reasonable feature
> > to use, and it evidently works everywhere that people care about.
> Heyho,
> Regarding the include used in various suckless projects: What is the
> benefit? If a user needs to adapt it to his system, he effectively has to edit a
> file. Would there be a problem if this file would be the Makefile instead of the
> file?

It is clear separation between user-configured variables and generic

It also makes it easy to have a configure script like as shown below:


case `uname` in
        ln config.bsd
        ln config.posix

This was taken from utmp[1].
This doesn't duplicate the entire Makefile.


Received on Tue Feb 11 2014 - 14:28:42 CET

This archive was generated by hypermail 2.3.0 : Tue Feb 11 2014 - 14:36:09 CET