Commit Graph

63 Commits

Author SHA1 Message Date
pooka d1cacc3197 fix pasto in error message
reported by Andrew Freedman in toolchain/17530
2002-07-09 06:36:16 +00:00
fredette 4234bc92d3 Add hppa as a supported MACHINE_ARCH. 2002-06-10 14:08:05 +00:00
augustss 2862ed3546 Remove redundant pattern in case. 2002-06-05 06:27:09 +00:00
thorpej 82d4bf2f9f Allow ns32k. 2002-06-05 02:32:15 +00:00
msaitoh 7c929f204a add armeb as valid MACHINE_ARCH 2002-05-24 14:43:31 +00:00
lukem 7d134e662e add "-M makeobjdirprefix" to build.sh 2002-05-13 01:44:34 +00:00
sommerfeld 965e0acae4 Correct BUGS in BUILDING.mdoc now that most ports are USE_NEW_TOOLCHAIN
Obsolete NBUILDJOBS; build.sh just passes -jN through to make(1),
which inherits it cooperatively through the build tree.  Fix
documentation so that it's shown to be deprecated.

If you use build -jN, please save full build logs so that errors due
to missing dependancies can be analyzed and corrected.
2002-05-02 22:13:30 +00:00
tv d5a1eec92f Bomb if share/mk/bsd.own.mk is missing. 2002-04-18 01:38:11 +00:00
thorpej 0c3d55ef67 Switch remaining ARM ports (acorn32, cats, shark) to ELF. 2002-04-02 16:34:49 +00:00
bjh21 dc96e428af Rename arm26 -> acorn26. 2002-03-24 22:21:41 +00:00
pk 19c8da4424 Crank up robustness. 2002-03-21 10:54:50 +00:00
thorpej e4732a956b Add a -B option to set the BUILDID for the build. This also causes
the make(1) wrapper script to be named "nbmake-MACHINE-BUILDID".
2002-03-14 18:33:04 +00:00
simonb a79fb9541b Add evbmips.
XXX: This is hard-coded to little-endian here, but there's not reason for
     some this.  The MALTA can be used with either-endianness.
2002-03-07 14:59:04 +00:00
simonb 92ae660710 Add sbmips. 2002-03-06 23:32:52 +00:00
tv 8ea025ea42 Nuke my "mkdirp" hack. "mkdir -p" is used so liberally throughout the
tree that the hack is just a maintenance annoyance here.
2002-03-02 03:51:02 +00:00
mjl 416ce5ecbb powerpc is a valid MACHINE_ARCH too. 2002-03-02 02:09:18 +00:00
tv be05d061b7 Related to PR toolchain/15780, sanity check MACHINE_ARCH. 2002-03-01 21:06:40 +00:00
tv 1e5d325cf1 Related to PR 15781, explain better in a comment why it is not possible
to grovel mk.conf using sed/awk/etc. before nbmake is available.
2002-03-01 20:57:26 +00:00
scw 3c68fd62d5 Add mvmeppc to powerpc case. 2002-02-27 21:19:08 +00:00
lukem c17ada6ca5 add -U; set UNPRIVED= 2002-02-27 13:55:28 +00:00
thorpej 91adf0a52c Shark is not yet MACHINE_ARCH=arm. 2002-02-10 19:09:13 +00:00
wiz f7d9c1c5ff s/dnard/shark/ 2002-02-10 18:28:12 +00:00
tv ff243397df chdir out of $tmpdir before removing it; some vendors' rm(1) programs will
not remove cwd....
2002-01-29 08:46:59 +00:00
tv d7938946ac Honor HOST_{CC,CFLAGS,CPPFLAGS,LDFLAGS} passed in from the environment
when building nbmake.  Use the correct defaults if not set (HOST_CC=cc,
HOST_CFLAGS=-O).
2002-01-19 16:49:28 +00:00
tv a4d805e9d2 Make sure buildmake.sh is run with "sh", rather than depending on executable
status.  (XXX we should probably come up with a HOST_SH variable for these
instances....)
2002-01-15 19:19:35 +00:00
tv 442feae097 Make use of new make(1) bootstrap in src/tools/make. 2002-01-15 19:17:23 +00:00
tv caacefb033 Apply workaround for some Bourne shells not handling IFS in the POSIX way.
Based on the change suggested by <david@l8s.co.uk> on current-users.
2001-12-19 20:59:07 +00:00
wiz cd1d503ed0 Sort options in usage in default order (AaBb...). 2001-12-17 13:16:10 +00:00
jmc eb0d4b304f Change check for USE_NEW_TOOLCHAIN to just looking for it being defined. 2001-12-12 23:50:27 +00:00
lukem 90d4be2b55 as -m mach is optional, indicate this in the usage 2001-12-11 23:57:49 +00:00
tv b7c526a551 Honor HOST_LDFLAGS in environment.
Add bash to the suggestions of alternative shells if /bin/sh isn't enough.
2001-12-11 21:13:35 +00:00
tv 906700c90b Revert part of rev. 1.28. DO NOT set MAKE_MACHINE, since "nbmake" is a
platform-independent binary.  It should have no default.  Setting MACHINE
is the purpose of the wrapper script.
2001-12-11 20:45:31 +00:00
jmc a0062bb4ae Make -t and -u behave together so a -t doesn't always force a cleandir in the
tools directory.
2001-12-09 06:07:16 +00:00
jmc b1561d46b2 Check if this platform is supported for USE_NEW_TOOLCHAIN and exit with a
complaint if it's not. Point out to run a traditional make and also how to
force a new toolchain build if one wants to test
2001-12-04 04:28:23 +00:00
jmc b24c81ca0c Make sure the makes running before the make build rule include
-m <top dir>/share/mk
2001-12-03 08:18:00 +00:00
thorpej a3c473186e - Define MAKE_MACHINE reasonably for the bootstrap make.
- Don't unset IFS; some shells don't like that.  Instead save, and
  restore IFS.
2001-11-30 02:18:13 +00:00
jmc df406df953 If using objdirs make sure the objdir root is made before starting the build.
Otherwise problems with bsd.own.mk and _SRC_TOP_OBJ can result.
2001-11-26 05:57:33 +00:00
thorpej 9b19c5d978 Add a "-d" option that uses the "distribution" target, rather than
the "build" target.
2001-11-25 18:35:06 +00:00
thorpej 9f11f1b5b4 If using -t, do a "cleandir" before building/installing the
tools.  This is something the old "build" hack used to do.
2001-11-15 00:14:35 +00:00
tv 8db91a3669 Revert part of rev. 1.20 -- $DESTDIR and $TOOLDIR are deliberately shown
symbolically with "-n", as these may come from mk.conf after building the
bootstrap make.  Add a comment to that effect.
2001-11-13 19:03:08 +00:00
tv b5cd2489b2 Major overhaul of src/tools and host toolchain. Summary of changes:
* Rewrite src/tools Make logic to work like the rest of the tree wrt
  "dependall" and "install".  The old "make build" hack is gone.

* Remove the MKTOOLS logic.  This was linked to the "make build" hack,
  and was only needed because TOOLDIR originally had no writable default.

* Redo the GNU configure/make logic to make it fit reasonably in a
  BSD make wrapper.  Use new ${.ALLTARGETS} variable to scan for
  targets in $(srcdir), and mark them with .MADE: to prevent rebuilding.

* Only build cross tools in src/tools; remove some messy logic in
  src/usr.* and src/gnu/usr.* that would do target filename rewriting
  (improves consistency and readability).

* Add the ability to build cross gdb at tool build time by setting
  MKCROSSGDB (default no) to "yes" in mk.conf.

* Add src/tools/groff and set up paths to work with this cross groff.
2001-11-12 23:16:17 +00:00
msaitoh 7e478326bd change MACHINE_ARCH of evbsh3 from sh3el to sh3eb because all config files
for evbsh3 defaults to big endian.
2001-11-12 08:54:58 +00:00
jmc a1ae34bc72 Always rebuild the nbmake wrapper script. Otherwise the options passed to
build.sh just get lost if they differ from a previous invocation (i.e. letting
MKOBJDIRS get set the first time, -o will get ignored after this unless a
rebuild of the script happens). It's low overhead so this adds little burden
to getting it right.
2001-11-11 01:34:30 +00:00
thorpej 3b569c7be3 * Fix a quoting error so that when using -n, we actually see
$TOOLDIR and $DESTDIR in their expanded form.
* Set USETOOLS=yes in the make wrapper script; it's pretty pointless
  using the make wrapper unless you're using the host tools.
* In the -t case, make sure to only echo the "make obj" command if -n.
2001-11-09 04:14:17 +00:00
dillo c5b59dd31e export DESTDIR when set via -D. 2001-11-05 02:17:47 +00:00
tv 472dcba2fb * Always use the makewrapper when starting a build phase.
* Set stuff mostly in the environment, not on make(1)'s command line.
  This is needed for MACHINE and MACHINE_ARCH (noted by bjh21), and keeps
  the mk.conf-overriding-env behavior (suggested by several people).

* Use MAKEFLAGS to make the wrapper script more readable.

* When prepping objdir in tools for the default TOOLDIR value, just make
  that objdir; leave the recursive "make obj" for later.
2001-11-02 05:07:22 +00:00
thorpej a4a68fe775 When doing an only-tools build, don't use the makewrapper. 2001-11-01 01:49:44 +00:00
thorpej f55ffb9482 Add a -t option that builds and installs the toolchain only
(and thus implies -b).  To make this work, we also check do_buildsystem
when doing the DESTDIR sanity check.
2001-11-01 00:14:17 +00:00
tv dadd6e7370 Major cleanup and overhaul:
* Allow MACHINE to be set automatically on NetBSD native builds.
  Require -m only if the host is not NetBSD.

* Fail if DESTDIR is set to root (/) and the build is not NetBSD native,
  or the build is attempting a "make release" (option -R).

* Warn the user if DESTDIR is set to root (/) that the kernel must be up
  to date, or else the build might hose the system.  Also, do not remove
  DESTDIR on -r if it is set to root.

* Fail if TOOLDIR is set to / or empty after checking with nbmake.

* Allow DESTDIR and TOOLDIR to be set in mk.conf and/or by the new default
  from <bsd.own.mk>.  Note that if -T is not used to set TOOLDIR, and
  TOOLDIR is not set in the environment, then nbmake will always be
  bootstrapped (rather than looking at nbmake's timestamp).  This is
  because /bin/sh doesn't know how to get TOOLDIR from mk.conf without
  first having nbmake (...which lives in TOOLDIR).

* Do a pass of "make obj" through src/tools before installing nbmake (so
  long as -o/MKOBJDIRS=no is not specified).  This ensures that objdirs
  exist if they are desired, and paves the way for using build.sh to
  build all the src/tools without building everything else.

* Add "-w" option, which allows the builder to specify where the nbmake
  wrapper shell script should be created.  If not specified,
  $TOOLDIR/bin/nbmake-$MACHINE is still created as a default.

* Print the values of DESTDIR and TOOLDIR after bootstrapping nbmake,
  for informational purposes.

It should now be possible to type just "./build.sh" on a NetBSD-current
host and get a new build in / for the appropriate architecture.
However, building in-place like this has *not* been extensively tested
yet, so be careful.
2001-10-31 19:59:43 +00:00
jmc a6ddeb5145 Add a sanity check. Don't rm -rf / if TOOLDIR or DESTDIR got set to / and -r
was an option
2001-10-31 18:23:55 +00:00