Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 24 Mar 2000 13:55:23 -0500 (EST)
From:      Matt Loschert <loschert@servint.com>
To:        Kenneth W Cochran <kwc@world.std.com>
Cc:        freebsd-stable@FreeBSD.ORG
Subject:   Re: Questions source-upgrading 3.4-s to 4.0-s
Message-ID:  <Pine.BSF.4.21.0003241327570.61712-100000@delft.servint.com>
In-Reply-To: <200003241710.MAA22784@world.std.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 24 Mar 2000, Kenneth W Cochran wrote:

> It appears that my new 4.0 system (& the new C compiler) will be
> built using the 3.4-stable tools; is this ok?  I'm guessing that
> the "last step(s)" of this process is to re-gen (cvsup/make
> [build, install]world...), just as I've always done with 3.x.

Before building your new 4.0 userland, the buildworld process builds the
4.0 compiler (gcc-2.95.2) (along with other build tools), and then uses
that to compile everything (including recompiling the compiler).

> It also appears that I cannot run a 3.x kernel with a 4.x
> userland (or is that a 4.x kernel with a 3.x userland?), so I
> have to get my userland built but not installed, then build,
> install & boot my new 4.x kernel, & *then* do my userland
> install (installworld).  Is this correct?

Yes, that's correct.

> <see notes below (updating to 4.0-stable sources>	[***]
> 	- I'm using the 4.x-stable-supfile from the examples in
> 	  3.4-s.  What are the best things to un-comment in that
> 	  config?  (to handle crypto things, for example...)

Make sure you specify to make 4.0-STABLE your default:
*default tag=RELENG_4

Use the following to get all 4.0-STABLE source including crypto:
src-all
cvs-crypto

If you want the latest ports collection and documentation, specify:
ports-all tag=.
doc-all   tag=.


> 	- What's the difference between what I'd get as North
> 	  American vs not?  (& what's the best way to "identify"
> 	  myself as North American?  (What is going to ship on
> 	  the CDs?)

Offhand, I am not sure what all of the differences are.  To identify
yourself as from USA, specify USA_RESIDENT="YES" in /etc/make.conf.
Then, point cvsup to a USA cvsup server in your supfile using something
like:
*default host=cvsup.FreeBSD.org


> cd /usr/src
> <see notes below>				[**]
> make buildworld
> 	- Ok...  This will take my new 4.x /usr/src & make a nice
> 	  new /usr/obj...

Yes.

> 	- MAKE_KERBEROS4 is already commented-out in my
> 	  /etc/make.conf, so I should be ok here?

Yes.

> cd sbin/mknod
> make install
> 	- What's this about?  Is this /usr/sbin/mknod or is it
> 	  /usr/src/sbin/mknod?
> 	  How does this differ from cd /dev; sh MAKEDEV?

cd /usr/src/sbin/mknod && make install

> cd sys/modules
> make install
> 	- Same here...  What's this about?  I'm thinking this (&
> 	  previous are relative to (my new 4.x) /usr/src, ie.
> 	  /usr/src/sys/modules, or perhaps /sys/modules...

cd /usr/src/sys/modules && make install


> <follow rebuild disk /dev entries above>	[*]
> 	- My system is all-scsi (/dev/da*).  Do I need to do
> 	  anything special?

Not if you have da* sepecified for you SCSI hard drives.  If you have sd*
devices, these need to be updated to da*.

> 	- "As above?"  Again, how does this differ from cd /dev;
> 	  sh MAKEDEV?

You need the new MAKEDEV script for 4.0 from /usr/src/etc.  As far as I
know, once you copy the new script into /dev, 'sh MAKEDEV all' should work
fine.  I could be wrong for certain configurations.

> reboot
> <in single user>
> 	- If I understand correctly, hit the spacebar & type -s<cr>?

You probably should boot into single-user, but I have done it successfully
after booting multi-user.

> cd /usr/src
> make -DNOINFO installworld
> 	- Why -DNOINFO?

The new texinfo IIRC relies on new features that are not part of the build
chain.  It tries to install itself using the existing install-info program
that does not have the features and bombs out.

-DNOINFO skips installing the info files, thus not needing the new
install-info.

> make installworld
> 	- & my guess is that this "corrects" the -DNOINFO
> 	  installworld I just did?

This essentially just installs the info files that were left out during
the previous step.

> reboot
> <multi-user>
> 	- At this time I'm guessing it would be a Very Good Idea
> 	  to do at least a [build, install]world, so as to get
> 	  everything built with the new C compiler & tools, etc...

Not necessary.  As mentioned above, the new compiler was used to do last
buildworld.

> To build a kernel
> -----------------
> cd /usr/src
> # If you have not already done so, please buildworld here
> make buildkernel KERNEL=<YOUR_KERNEL_HERE>
> make installkernel  KERNEL=<YOUR_KERNEL_HERE>
> # Verify that the new kernel works, it will be installed as
> # /YOUR_KERNEL_HERE
> chflags noschg /kernel
> mv /kernel /kernel.old
> mv /YOUR_KERNEL_HERE /kernel
> chflags schg /kernel
> 
> 	- Is this still the same as:
> 	cd /sys/i386/conf
> 	<config things...>
> 	config <whatever, probably GENERIC in this case...>
> 	cd /sys/compile/GENERIC
> 	make depend
> 	make
> 	make install

The kernel build process that you are familiar with relies on already
installed tools.  Since the new 4.0 tools are not installed at this point,
you can't use them to build your 4.0 kernel.  The buildkernel and
installkernel targets use tools built (but not installed) during the
buildworld phase to ensure that everything is in sync.

> 	- Other than that, I'm guessing that I need to build &
> 	  install the GENERIC kernel?

For the upgrade, yes, install GENERIC.  Once you have rebooted after the
upgrade, it is much safer to rebuild your custom kernel.

Hope this helps.

- Matt

--
Matt Loschert                           loschert@servint.com
Software Engineer                       voice (703) 847-1381
ServInt Internet Services               fax   (703) 847-1383





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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0003241327570.61712-100000>