Subject: Re: make kernel question
To: None <>
From: Mike Long <>
List: current-users
Date: 06/03/1997 19:36:24
>Date: Tue, 03 Jun 1997 13:33:40 -0400
>From: "Perry E. Metzger" <>
>noud de brouwer writes:
>> >noud de brouwer writes:
>> >> hi all,
>> >> NetAtalk sounded so attractive to me,
>> >> so i grabbed the sys.tar.gz from current,
>> >> unpacked in a 1.2.1 NetBSD /usr/src creating sys.
>> >Unfortunately, you CAN'T just upgrade your kernel.
>> >I would suggest that if you want to upgrade to -current, you should
>> >upgrade to -current, and not try doing this piecemeal.
>> i thought: build kernel and then build binaries
>Actually, if you want to upgrade from sources, you have to do it the
>other way around, since you need a new userland to build a new kernel

I think it might be helpful to clarify this a bit.  The order in which
you have to upgrade things is generally:

1) Rebuild "tools".   Usually "tools" includes everything you need to
build the kernel and libraries.  You should always rebuild at least:

make, sh, config, gas, ld (but NOT, and gcc.

Note that all of these are linked against the libraries already
existing on your system, so you should be fine unless one of them uses
a new syscall which your older system doesn't support (unlikely).  In
that case you must start looking for a binary snapshot, or hope that
you can get away with using your old binary.

2) Configure, build, and install a new kernel.  Be sure to keep your
original kernel around in case of lossage.  Note that you may need
some COMPAT_xx options in your new kernel in order for your old code
to work properly.

3) Update headers (/usr/include), libraries, and everything else.

If you grab someone else's prebuilt libraries and binaries and blindly
try to use them with your older kernel, you are asking for major
lossage.  Hence, if you get a snapshot install the kernel first, then
install the libraries and binaries only after rebooting.

I hope that makes things a little bit clearer.
Mike Long <>      
"Every normal man must be tempted at times to spit on his hands,
hoist the black flag, and begin slitting throats." -- H.L. Mencken