Subject: Re: bin/13285: bsd.sys.mk/MKSOFTFLOAT
To: NetBSD Bugs and PR posting List <netbsd-bugs@NetBSD.ORG>
From: Greg A. Woods <woods@weird.com>
List: netbsd-bugs
Date: 06/25/2001 12:16:54
[ On Monday, June 25, 2001 at 13:56:50 (+1000), Simon Burge wrote: ]
> Subject: Re: bin/13285: bsd.sys.mk/MKSOFTFLOAT 
>
> Greg A. Woods wrote:
> > 
> > Index: bsd.sys.mk
> > ===================================================================
> > RCS file: /cvs/NetBSD/src/share/mk/bsd.sys.mk,v
> > retrieving revision 1.1.1.9
> > diff -c -c -r1.1.1.9 bsd.sys.mk
> > *** bsd.sys.mk	2001/06/19 18:59:00	1.1.1.9
> > --- bsd.sys.mk	2001/06/21 21:44:18
> > ***************
> > *** 2,7 ****
> > --- 2,12 ----
> >   #
> >   # Overrides used for NetBSD source tree builds.
> >   
> > + .if !target(__bsd.sys.mk-initialized__)
> > + __bsd.sys.mk-initialized__:
> > + .include <bsd.own.mk>
> > + .endif
> > + 
> >   .if defined(WARNS)
> >   .if ${WARNS} > 0
> >   CFLAGS+= -Wall -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith
> 
> 
> Index: bsd.sys.mk
> ===================================================================
> RCS file: /cvsroot/sharesrc/share/mk/bsd.sys.mk,v
> retrieving revision 1.47
> diff -d -p -u -r1.47 bsd.sys.mk
> --- bsd.sys.mk	2001/06/18 17:04:45	1.47
> +++ bsd.sys.mk	2001/06/25 03:53:21
> @@ -2,6 +2,15 @@
>  #
>  # Overrides used for NetBSD source tree builds.
>  
> +.if !target(__initialized__)
> +__initialized__:
> +.if exists(${.CURDIR}/../Makefile.inc)
> +.include "${.CURDIR}/../Makefile.inc"
> +.endif
> +.include <bsd.own.mk>
> +.MAIN:		all
> +.endif
> +
>  .if defined(WARNS)
>  .if ${WARNS} > 0
>  CFLAGS+= -Wall -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith
> 
> follows that the other *.mk files appear to do.  Is there any reason
> to be different in for the bsd.sys.mk case?  I haven't yet finished a
> "make release" on a non-MKSOFTFLOAT system yet though...

Well, it wasn't done that way before and since there are lots of
"Makefile.inc" files in places where users of <bsd.sys.mk> probably
already exist, it seemed much safer to me to just do only what was
necessary and not try to do something extra just for the sake of some
arbitrary sake of consistency, something that might not actually make
sense in the real-world cases.


> > Oh, and while I'm here, this is pretty handy for some of us too...
> > 
> > ***************
> > *** 54,60 ****
> >   
> >   OBJCOPY?=	objcopy
> >   STRIP?=		strip
> > ! CONFIG?=	config
> >   RPCGEN?=	rpcgen
> >   MKLOCALE?=	mklocale
> >   
> > --- 59,65 ----
> >   
> >   OBJCOPY?=	objcopy
> >   STRIP?=		strip
> > ! CONFIG?=	/usr/sbin/config
> >   RPCGEN?=	rpcgen
> >   MKLOCALE?=	mklocale
> 
> How does hard-coding the path to config(8) and not other binaries help
> out?  I'm don't understand the reasons for this suggested change...

Well, mostly because I really detest having to do builds as root and I
really detest having to have /usr/sbin (and /sbin) in my non-root PATH.

I'm quite happy with 'config' living in /usr/sbin (it's pretty system
specific and not much good for anything but building kernels) -- I just
think that "programs" which use it should take care to find it there
explicitly since that's a "non-standard" place as such things go.

I could fix this in /etc/mk.conf, I think, but it seems best to do it
generically since anyone and everyone doing what I'm doing will end up
with the same problem.

-- 
							Greg A. Woods

+1 416 218-0098      VE3TCP      <gwoods@acm.org>     <woods@robohack.ca>
Planix, Inc. <woods@planix.com>;   Secrets of the Weird <woods@weird.com>