Subject: Re: Suggested addition to build.sh
To: Todd Vierling <tv@wasabisystems.com>
From: David Brownlee <abs@netbsd.org>
List: tech-toolchain
Date: 05/17/2002 16:20:42
On Fri, 12 Apr 2002, Todd Vierling wrote:

> On Fri, 12 Apr 2002, David Brownlee wrote:
>
> : 	How about an option to build a generic kernel into $DESTDIR?
> : 	(Standard warnings about installing into /)
> :
> : 	It could be used on its own, or as part of a -d build.
>
> Problem is that many ports don't have a "GENERIC".  :)
>

	That could be handled by defaulting to GENERIC but allowing
	it to be overridden. eg './build.sh -K' or './build.sh -K FUBAR'

> Basically, to build a kernel as part of upgrading to -current by source:
>
> ./build.sh -t [-T $TOOLDIR]
> cd sys/arch/$MACHINE/conf
> $TOOLDIR/bin/nbconfig $KERNCONFNAME
> cd ../$KERNCONFNAME
> $TOOLDIR/bin/nbmake-$MACHINE all
>
> This corresponds to established practice for building a custom kernel; it
> just uses the cross-toolchain created by "build.sh -t".

	I have a trivial shell script that pretty much does the above, but
	I think for someone new to NetBSD having to remember (or even
	be able to find) the above commands makes it harder than it needs
	to be to update a kernel.

	It would be much nicer to be able to tell them to run
	'./build.sh -K FUBAR', which run the above, then displays:
		"The FUBAR kernel is now in \
			../sys/arch/$MACHINE/compile/$KERNCONFNAME/netbsd"

-- 
		David/absolute		-- www.netbsd.org: No hype required --