Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Oct 2001 20:38:43 +0300
From:      Ruslan Ermilov <ru@FreeBSD.org>
To:        "David O'Brien" <obrien@FreeBSD.org>, Bruce Evans <bde@FreeBSD.org>
Cc:        cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/sbin/conscontrol Makefile
Message-ID:  <20011025203843.B54744@sunbay.com>
In-Reply-To: <20011025102152.B31465@dragon.nuxi.com>; from obrien@FreeBSD.org on Thu, Oct 25, 2001 at 10:21:52AM -0700
References:  <200110251709.f9PH9bD60901@freefall.freebsd.org> <20011025201245.L41293@sunbay.com> <20011025102152.B31465@dragon.nuxi.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Oct 25, 2001 at 10:21:52AM -0700, David O'Brien wrote:
> On Thu, Oct 25, 2001 at 08:12:45PM +0300, Ruslan Ermilov wrote:
> > On Thu, Oct 25, 2001 at 10:09:37AM -0700, Ruslan Ermilov wrote:
> > > ru          2001/10/25 10:09:37 PDT
> > > 
> > >   Modified files:
> > >     sbin/conscontrol     Makefile 
> > >   Log:
> > >   Put WARNS into the right place.
> > >   
> > >   Revision  Changes    Path
> > >   1.4       +1 -1      src/sbin/conscontrol/Makefile
> > > 
> > Simple makefiles should put variables sorted by their use.
> > In this case, CFLAGS (which the WARNS is part of) is used
> > before MAN.
> 
> Actually that is not right.  "products" come first.  This means PROG and
> MAN are above SRCS and CFLAGS.  There is CSRG precedence for this (I
> believe I emailed you it in the past).
> 
> Please revert this back to rev 1.3.
>  
No.  Most of the other WARNSified makefiles use that style.

PROG=	foo
SRCS=	foo.c bar.c
CFLAGS+=-DFOO
WARNS?=	2
MAN=	foo.8

WARNS relates to CFLAGS.
CFLAGS relates to SRCS.
SRCS defaults to PROG and is optional.

For a standard bsd.prog.mk user, put it so if you had no manpage,
and build with -DNOMAN.

It's still unclear to me should we separate the building stuff and
installation stuff like BINDIR, LINKS, and MANSUBDIR.

The prototype bsd.prog.mk makefile that doesn't use .if's may look
like this:

PROG=
SRCS=
CFLAGS=
DPADD=
LDADD=
BINDIR=
[SYM]LINKS=
MAN=
MLINKS=

WARNS being a special case of CFLAGS.

> > /me badly needs to find time for Makefile.style(7).
> 
> You, BDE and I do need to finish that off.
> 
Definitely.


Cheers,
-- 
Ruslan Ermilov		Oracle Developer/DBA,
ru@sunbay.com		Sunbay Software AG,
ru@FreeBSD.org		FreeBSD committer,
+380.652.512.251	Simferopol, Ukraine

http://www.FreeBSD.org	The Power To Serve
http://www.oracle.com	Enabling The Information Age

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011025203843.B54744>