Subject: Correct build method?
To: None <NetBSD-help@NetBSD.org>
From: Greg 'groggy' Lehey <grog@lemis.com>
List: current-users
Date: 12/27/2002 13:22:41
I'm copying current-users@ on this message, since it may be related to
CURRENT.

Once upon a time, upgrading a system seemed simple.  You unpacked the
source code and ran a 'make build'.  That doesn't seem to work any
more.

Yesterday I installed a fresh 1.6-RELEASE system and checked out the
latest -CURRENT sources, then tried 'make build'.  It died with the
following message:

  cleandir ===> gnu/usr.bin/grep
  rm -f grep.o dfa.o kwset.o obstack.o savedir.o getopt.o getopt1.o search.o stpcpy.o regex.o grepmat.o  grep.ln dfa.ln kwset.ln obstack.ln savedir.ln getopt.ln getopt1.ln search.ln stpcpy.ln regex.ln grepmat.ln
  rm -f grep.1 grep.info grep.cat1  
  rm -f a.out [Ee]rrs mklog core *.core .gdbinit grep
  rm: grep: is a directory
  *** Error code 1

I find this puzzling, since the files are all straight from the repo
with no changes.  Anyway, I RTFMd (well, RTFFAQd at
http://www.netbsd.org/Documentation/current/#why-track), and did:

    * Build the toolchain.
      From the root of the source tree, run './build.sh -t'. This will
      build a toolchain in tools/obj/tools.<hostplatform>/bin.
    * Build and install the kernel.
          o cd sys/arch/ARCH/conf
          o .../tools/obj/tools.<hostplatform>/bin/nbconfig GENERIC
          o cd ../compile/GENERIC
          o .../tools/obj/tools.<hostplatform>/bin/nbmake-ARCH
    o make install (this will rename /netbsd to /onetbsd and install
      the new kernel as /netbsd).
  * Reboot into the new kernel

This all worked well.  Next step is:

  * Run ./build.sh

Without any arguments, this dies on me with the message 

  ERROR: DESTDIR must be set to a non-root path for non -E (expert) builds
  *** BUILD ABORTED ***

OK, so I tried with -E and -d foo.  In each case, see number 1:

  rm: grep: is a directory
  *** Error code 1

Questions:

1.  What am I doing wrong?
2.  Why am I getting this message?
3.  Does 'make build' no longer work?

Greg
--
Finger grog@lemis.com for PGP public key
See complete headers for address and phone numbers