Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 16 May 2012 18:46:28 -0400
From:      "Thomas Mueller" <mueller23@insightbb.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: Building FreeBSD to install or update in two DESTDIRs
Message-ID:  <F3.96.21955.44E24BF4@smtp01.insight.synacor.com>

next in thread | raw e-mail | index | archive | help
> > The idea was to "make buildkernel" once and "make buildworld" once
> > and install to two different DESTDIRs.

> I'm not sure I understand: The two install* targets ("make installkernel"
> and "make installworld") are only able to install to _one_ location,
> which is the _default_ location *or* the location pointed to by
> DESTDIR. It is not possible to perform _one_ install step which
> will cause results in _two_ locations (without any means of
> "hidden duplication", e. g. by using a mirroring technique).

The idea was to "make buildkernel" once and "make buildworld" once, but "make installkernel" and "make installworld" would each have to be done once for each DESTDIR, meaning twice each.  Building takes much more computer resources than installing, so I try to avoid building the same thing twice.

> I'm refering to the instructions presented in /usr/src/Makefile:

> # For individuals wanting to upgrade their sources (even if only a
> # delta of a few days):
> #
> #  1.  `cd /usr/src'       (or to the directory containing your source tree).
> #  2.  `make buildworld'
> #  3.  `make buildkernel KERNCONF=YOUR_KERNEL_HERE'     (default is GENERIC).
> #  4.  `make installkernel KERNCONF=YOUR_KERNEL_HERE'   (default is GENERIC).
> #       [steps 3. & 4. can be combined by using the "kernel" target]
> #  5.  `reboot'        (in single user mode: boot -s from the loader prompt).
> #  6.  `mergemaster -p'
> #  7.  `make installworld'
> #  8.  `make delete-old'
> #  9.  `mergemaster'            (you may wish to use -i, along with -U or -F).
> # 10.  `reboot'
> # 11.  `make delete-old-libs' (in case no 3rd party program uses them anymore)

I checked /usr/src/UPDATING, and the sequence was

...
<reboot in single user mode>
mergemaster -p 
make installworld
mergemaster -i  (one may wish also -U)
make delete-old
<reboot>

I checked /usr/src/Makefile , and found you quoted correctly, see 'make delete-old' and the second 'mergemaster' are transposed relative to what I saw in /usr/src/UPDATING 

Sort of confusing; make either way works?

Subsequently I would also want to build for i386, but this would be after the amd64 build and installation/update.

It would be nice if bsdinstall had an option for update as well as fresh install.

For i386, I would follow advice on http://wiki.freebsd.org/Wine but would want a full installation capable of running independently of amd64, would need the kernel, would install on 16 GB USB stick which could be mounted on /compat/i386.  I would want to use hard-drive PORTSDIR, would need to so adjust /etc/make.conf .  I don't really want to think of building big ports on a USB stick, especially on the older computer with 256 MB RAM and USB 1.1 on motherboard.

Tom



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