Commit Graph

628 Commits

Author SHA1 Message Date
bdrewery
3baadfba33 Fix the .MAKE added in r251750 to properly support the historical -n -n.
The condition used matches the condition in sys.mk for setting _+_ to blank
or +.

With this -n will continue to not descend into Makefile.inc1, while -n -n will
and cause Makefile.inc1's target to run with -n.

MFC after:	2 weeks
Sponsored by:	EMC / Isilon Storage Division
2015-09-29 18:57:30 +00:00
bdrewery
c573883774 Rework r287900 to keep arm64/aarch64 stable in the TARGETS list.
This is relevant for makeman using the 'make targets' output in src.conf(5).

This makes a _UNIVERSE_TARGETS that removes arm64 if the build
requirements are not met.
2015-09-17 04:54:49 +00:00
bdrewery
56dcc079a6 Get arm64/aarch64 into 'make targets' output to fix makeman. 2015-09-17 04:43:07 +00:00
bapt
ef64c24c72 Rename kernel-pkgs into create-kernel-packages to be consistent with world 2015-09-12 11:45:10 +00:00
bapt
b59c5e751e Merge from head 2015-09-12 11:41:31 +00:00
sjg
36cfe02ee5 Fix generation of src.conf.5
Since makeman turns all options on, we need to guard somethings from
make(showconfig)
2015-07-03 06:10:09 +00:00
sjg
02d7ae730f targets now needs .PHONY 2015-06-22 16:13:17 +00:00
bapt
bb8dfd5e7e Merge from head @274131 2015-06-20 00:58:46 +00:00
andrew
f77ffa00d7 Move the universe done dependency on the worlds completing out of the
loop, we only need to add it once.

Obtained from:	ABT Systems Ltd
2015-06-16 21:29:46 +00:00
andrew
cc6feff88b Remove unneeded dependencies, these are now handled through the _done
target.

Obtained from:	ABT Systems Ltd
2015-06-16 21:11:31 +00:00
bapt
686222ed26 Merge from head@274131 2015-06-16 20:01:01 +00:00
andrew
49fddee16c Add a new target universe_${target}_done to print the completion message.
Without this we could print this message in the wrong place when building
with MAKE_JUST_WORLDS is set.

Obtained from:	ABT Systems Ltd
2015-06-16 19:23:34 +00:00
andrew
4965812c17 Add a universe_${target}_worlds target to simplify the logic to find when
to start building kernels.

Obtained from:	ABT Systems Ltd
2015-06-16 18:43:08 +00:00
imp
cc2270d116 A more compatible fix to MK_META_MODE not being defined. Also, encase
bmake specific constructs not needed for make bootstrap so fmake
doesn't see them. This works with fmake just well enough for us to
build bmake to build the rest of the tree without fatal errors. Tested
only with fmake package.
2015-06-16 17:55:20 +00:00
andrew
e745842edf Add a comment to the end of the world and kernel cases in the universe
target to help follow the make magic.

Obtained from:	ABT Systems Ltd
2015-06-16 17:27:53 +00:00
bapt
35a6f0a11c Merge from head 2015-06-15 10:56:01 +00:00
rodrigc
b4fa227025 If MK_META_MODE is unset, assume a value of no.
This is needed to build HEAD on FreeBSD 10.1,
which has bmake, but does not have
/usr/share/mk/src.opts.mk

Reviewed by: sjg
Reported by: jenkins
2015-06-14 22:36:27 +00:00
sjg
167576cd47 Since sys.mk now handles META_MODE and META_FILES options
we need not worry about them here.
Checking for .PARSEDIR no longer needed.
2015-06-10 13:08:45 +00:00
sjg
65145fa4c8 Merge sync of head 2015-05-27 01:19:58 +00:00
bapt
b5633ba2a5 Merge from head 2015-05-03 19:30:11 +00:00
emaste
7df2e586a8 Don't add arm64 to universe builds if the user provided a TARGETS list
Differential Revision:	https://reviews.freebsd.org/D2375
Reported by:	andrew
Reviewed by:	andrew, imp
Sponsored by:	The FreeBSD Foundation
2015-04-28 17:13:05 +00:00
ngie
9f8c86b0c0 Fix a typo (linnker -> linker) 2015-04-27 18:21:42 +00:00
emaste
01e375543f Add arm64 to universe if binutils is available.
arm64 relies on an external binutils port or package right now, because
the in-tree linker from binutils 2.17.50 does not support arm64. Add
arm64 to universe if the linker is available. If not output a message
that arm64 is skipped.

buildworld and buildkernel use the external binutils automatically, so
it's sufficient to run 'pkg install aarch64-binutils' to build
FreeBSD/arm64.

Differential Revision:	https://reviews.freebsd.org/D2302
Reviewed by:	andrew, imp
Sponsored by:	The FreeBSD Foundation
2015-04-16 22:35:19 +00:00
bapt
ef3b6ff94c Merge from HEAD 2015-04-03 23:23:09 +00:00
imp
16676d0f06 Make TARGET_ARCH=powerpc64 work without TARGET=powerpc. 2015-03-21 16:54:01 +00:00
andrew
0c72282747 Start to import support for the AArch64 architecture from ARM. This change
only adds support for kernel-toolchain, however it is expected further
changes to add kernel and userland support will be committed as they are
reviewed.

As our copy of binutils is too old the devel/aarch64-binutils port needs
to be installed to pull in a linker.

To build either TARGET needs to be set to arm64, or TARGET_ARCH set to
aarch64. The latter is set so uname -p will return aarch64 as existing
third party software expects this.

Differential Revision:	https://reviews.freebsd.org/D2005
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
2015-03-19 13:53:47 +00:00
bapt
65cc261694 Create a "packages" target takes care of all the magic 2015-03-15 14:05:55 +00:00
bapt
5c62d95dc8 Add new create-world-packages target to generated the packages out of world
Dynamically figure out the list of targets based on tags passed on the mtrees
First sanity check that all packages have existing manifests
Generate the packages

Please note that for now the mtree needs more work as it has duplicate entries,
everything is not yet tagged

The packages now have generic entries and needs to be customize
2015-03-05 00:13:42 +00:00
bapt
bf9037b831 Add a new target make stageworld which basically does the same job as:
make installworld distribution but preparing the mtree the same way
distributeworld does and respecting -DNO_ROOT
2015-02-10 22:05:57 +00:00
bapt
943258e782 Plug kernel-pkgs target to the list of valid targets 2015-02-08 18:16:20 +00:00
sjg
d98d3ee218 If we are doing META_MODE use targets/Makefile as top-level
since this one isn't suitable.
2014-11-30 18:50:15 +00:00
sjg
b137080f19 Merge from head@274682 2014-11-19 01:07:58 +00:00
kevlo
212d5d739c Revert r271159, Mis-patched the tree.
Pointed out by:	kib
2014-09-05 14:35:34 +00:00
kevlo
dadcc9c0d2 The USB LED driver for the Dream Cheeky WebMail Notifier.
Reviewed by:	hselasky
2014-09-05 11:25:58 +00:00
sjg
d7cd1d425c Merge head from 7/28 2014-08-19 06:50:54 +00:00
imp
1ddbac150a Create the native-xtools target. This target creates only the cross
building toolchain for the host computer. This toolchain produces
TARGET_ARCH and assumes the rest of the system contains libraries for
the target. It is intended to be used in a "qemu-user jail" where all
the binaries would otherwise be the target architecture's to build
ports. However, emulation of the compilers is too slow, so we build
native binaries for that. Rather than use the xdev produced binaries,
with all their weird links and paths, these binaries use the native
paths. They will not work unless installed into the qemu-user jail.

Differential Revision: https://phabric.freebsd.org/D518
Reviewed by: sbruno@
2014-08-18 21:04:44 +00:00
imp
32765bc6eb Add compat shims for XDEV and XDEV_ARCH so we don't break all the
users of them. Also, add a note to updating. We'll keep these shims at
least until the 12 branch.
2014-07-24 06:16:51 +00:00
jmmv
0b964c341a Explicitly disable the build of tests when building bmake.
During "make buildworld", building bmake is (one of) the very first steps
and we should not be building any of its tests.  Conceptually, this is the
right thing to do 1) for build simplicity reasons and 2) because there is
no need to build any tests this early on.

In practice, this fixes tinderbox builds of CURRENT from 9.x when MK_TESTS
is enabled.  This is because bsd.test.mk needs some modern bmake features
not present in 9.x (:tW) and tinderbox is forcing the build to use the
CURRENT share/mk files from the very beginning (see r266617).  By skipping
the build of the tests when still using the host make, we omit the problem.
Arguably, what tinderbox is doing is wrong and needs to be addressed, but
that is a separate issue.
2014-07-13 23:53:41 +00:00
imp
cb693195c6 Separate out the links creation from the other targets. This was
supposed to have been done for the original commit, but somebody
forgot.

Pointy-hat-to:  imp@
2014-07-10 18:28:12 +00:00
marcel
c8daee6da0 Remove ia64 from the list of known architectures and add an entry to
UPDATING. This is the first step towards the removal of ia64 from
head. A buildworld for ia64 will now yield:

% make buildworld
make[1]: "/usr/src/Makefile.inc1" line 151: Unknown target ia64:ia64.

While here, trim the ia64-specific additions from ObsoleteFiles.inc

Discussed at: BSDcan
2014-07-02 22:34:06 +00:00
imp
d0cce18ef3 grep -L returns non-zero status if none of the files had the pattern
in them. This is often the case, so just ignore the return
code. Actual errors that are found will also be detected downstream in
the rare cases where the return code is 2 instead of 1.
2014-05-10 16:39:08 +00:00
imp
c6d68cfa0a We haven't done anything with _UPGRADING in ~forever (was present, but
not needed, in FreeBSD 6.x, and has been absent in newer versions).
This was needed to upgrade from 3.x -> 4.x, once upon a time.
2014-05-10 16:38:45 +00:00
imp
36d46e4494 Remove a few more vestiges of allowing WITHOUT_BMAKE to imply you want
to buid with fmake.
2014-05-10 16:37:33 +00:00
sjg
ed3fc70bf5 Merge from head 2014-05-08 23:54:15 +00:00
imp
25fb261e2f No need to install man pages for bootstrapping new make. Some
environments (that I can't reproduce locally, but that others have
reported) seem to get tripped up by this man page install. There's
really no need to do it, so turn off the man pages using the most
portable method. We can't just directly set MK_MAN=no here because
we're bootstrapping in the host environment and such a setting was
forbidden until very recently. NO_MAN= can produce a warning, but for
now the warning is benign.
2014-05-06 15:44:46 +00:00
imp
3be1d4bf0f Remove support for WITHOUT_BMAKE. bmake is now the only make that can
build world, so it is the only make we build or install. fmake is
still in the tree, but disconnected, and upgrades from older systems
that still have bmake has not been removed, but its state has not been
tested (it should work given how minimal the work to upgrade to bmake
is).
2014-05-06 04:22:37 +00:00
sjg
437cf0a8f3 If building WITH_META_FILES we do not want STAGING 2014-05-05 18:32:24 +00:00
imp
c55ab52e3f Omit from the universe build all config files tagged with
#NO_UNIVERSE. Many of these config files are important examples, but
add little to no regresive value to the intended purpose of
UNIVERSE. We now build over 120 kernels during universe. There's
really little to no value to this over building say 60 or even 30 of
them (either is still a way too big number). This is especially true
for kernels that are nothing more than including a common base and
adding a static DTB file. Start by pruning 1/3 of the arm kernels that
add little regresion value.
2014-04-30 18:02:10 +00:00
brooks
0a3c433fc7 Merge from CheriBSD:
commit 1d1b908107255ffdff4d17f015d8f057d73cc6cb
Author: Brooks Davis <brooks@one-eyed-alien.net>
Date:   Fri Mar 28 16:24:45 2014 +0000

    Add a long needed seatbelt.

    Exit with an error when make is called without a target at the top level
    rather than poluting the source tree and causing use confusion in future
    builds.

commit a9d9aa341b2f4308a227ab460ba85f1f287ad028
Author: Brooks Davis <brooks@one-eyed-alien.net>
Date:   Tue Apr 29 16:06:12 2014 +0000

    Simplify seatbelt added in 1d1b908 based in feedback.

    Discussed with:	imp@FreeBSD.org

Reviewed by:	imp
Sponsored by:	DARPA, AFRL
2014-04-29 16:57:25 +00:00
sjg
5e568154a0 Merge head 2014-04-28 07:50:45 +00:00
jmmv
534840ba27 Prevent building tests when bootstrapping make.
Should fix the breakage reported by tinderbox when WITHOUT_BMAKE is set,
which was probably introduced in r263346..
2014-04-21 22:36:31 +00:00
brueffer
8104663b03 Document the xdev* targets.
PR:		188519
Submitted by:	Idwer Vollering <vidwer at gmail.com>
Reviewed by:	bapt
MFC after:	1 week
2014-04-14 16:15:11 +00:00
imp
afbcb69486 We no longer support upgrading from FreeBSD 4, so we don't need the
NOMAN and NOSHARED defines here. They have been obsolete for almost a
decade anyway.
2014-04-13 05:21:35 +00:00
imp
8131bb3d73 Remove support for legacy mips*eb names. Remove tests for
TARGET_BIG_ENDIAN.
2014-04-01 14:24:25 +00:00
andrew
8842d57879 Add a new ARM TARGET_ARCH, armv6hf. This is considered experimental.
This targets the existing ARMv6 and ARMv7 SoCs that contain a VFP unit.
This is an optional coprocessors may not be present in all devices, however
it appears to be in all current SoCs we support.

armv6hf targets the VFP variant of the ARM EABI and our copy of gcc is too
old to support this. Because of this there are a number of WITH/WITHOUT
options that are unsupported and must be left as the default value. The
options and their required value are:
 * WITH_ARM_EABI
 * WITHOUT_GCC
 * WITHOUT_GNUCXX

In addition, without an external toolchain, the following need to be left
as their default:
 * WITH_CLANG
 * WITH_CLANG_IS_CC

As there is a different method of passing float and double values to
functions the ABI is incompatible with existing armv6 binaries. To use
this a full rebuild of world is required. Because no floating point values
are passed into the kernel an armv6 kernel with VFP enabled will work with
an armv6hf userland and vice versa.
2014-03-23 12:49:25 +00:00
sjg
971be67d00 Make it possible to buildworld, while producing .meta files to aid
debugging.
2013-10-16 16:05:49 +00:00
sjg
7fcd33c1fa Merge head@256284 2013-10-13 02:35:19 +00:00
andrew
79894c6080 Remove the armv6eb architecture as it is unused, and almost certainly
broken. None of our kernels can boot armv6eb. The little-endian kernels do
not have the required code to be able to switch endian when running a
big-endian executable.

Approved by:	re (gjb)
2013-09-22 07:30:17 +00:00
emaste
a54f6a9645 Further refinement to bmake bootstrapping
Include PROGNAME and DESTDIR in ${MMAKE} so that it doesn't need to be
passed to each make invocation.

Suggested by:	hrs
Reviewed by:	hrs
Approved by:	re (gjb)
2013-09-19 20:09:56 +00:00
emaste
d9412a6c2d Fix make bootstrapping with WITH_DEBUG_FILES=
A HEAD buildworld on 9.x first bootstraps bmake, but this failed when
building with standalone debug.  Pass in the PROGNAME override to the
'make all' stage as well as 'make install' so that the .debug file is
created with the correct name.

Reviewed by:	sjg
Sponsored by:	The FreeBSD Foundation
Approved by:	re (rodrigc)
2013-09-12 00:23:09 +00:00
sjg
ff87b5d147 Merge head 2013-09-11 18:16:18 +00:00
sjg
4a6a9b0a75 During universe/tinderbox export MAKE_JOB_ERROR_TOKEN=no
This avoids aborting everything when one kernel fails.

Reviewed by:	obrien
2013-09-06 02:57:15 +00:00
sjg
62bb106222 Merge from head 2013-09-05 20:18:59 +00:00
sjg
323981dede Don't let user specified DESTDIR, break building our chosen make. 2013-08-17 04:41:35 +00:00
sjg
750a378414 When we need to build using the in-tree make,
switch at the earliest opportunity.
In the case of fmake vs bmake, this helps ensure correct load handling.

Reviewed by: obrien
2013-08-16 16:26:23 +00:00
sjg
25bd9fd1d5 Fix bug in universe where if upgrade_checks wants a new make,
it gets built 16 times in parallel in the same location.
While we are at it, until we finish getting rid of fmake,
be explicit about the make we want to use, thus avoid the problem
of the temp make being the wrong version.

Reviewed by:	obrien
2013-07-24 17:55:08 +00:00
alfred
c7a08860c7 Correct typo specifying jflags. 2013-07-07 20:44:04 +00:00
alfred
0d897a2a05 Document tip on how to build all kernels quickly. 2013-07-07 20:39:11 +00:00
sjg
a6ae521803 Flag recursive make targets with .MAKE
so that job token pipe is passed to them.
To avoid surprising anyone, only add .MAKE to ${TGTS} when -n
has not been specified (at least for Makefile).

Reviewed by:	obrien
2013-06-14 16:30:11 +00:00
sjg
4576f811af Ensure this makefile and anything it runs, does so without meta mode.
Allows buildworld etc.
2013-06-04 15:27:41 +00:00
sjg
0ffaee9c19 bmake does not like universe_${target}_prologue in the .ORDER
when there is an explicit dependency for it anyway.
Remove it so both bmake and fmake do the same thing.

Reviewed by:	OBrien
2013-06-03 23:51:46 +00:00
crees
d095ed802f Make the instruction order for buildworld agree with UPDATING and the
Handbook.

Reviewed by:	imp, bdrewery, netchild
Approved by:	gjb (mentor)
2013-05-29 19:16:59 +00:00
sjg
70d21b25e5 Reverse the sense of the test wrt bmake, and guard against
MK_BMAKE not being defined.
2013-05-16 21:26:46 +00:00
sjg
5f0af63a3f If doing buildworld -DWITH_BMAKE make sure bmake does the build. 2013-04-12 00:34:19 +00:00
dim
777e0f8e3a Ensure make -j N universe works correctly, by checking for an up-to-date
make before starting the universe targets themselves.  Otherwise, all of
the targets would attempt to build make simultaneously, overwriting each
other's copies of the make object files and executable.  This could lead
to strange errors, for example when partially-written make executables
are invoked.

Also amend r216620, to make the rest of universe wait properly until the
upgrade_checks target is finished, by adding universe_${target}_prologue
to the .ORDER target.  Otherwise, make will be too smart for its own
good, and start building the universe targets simultaneously with the
prologues anyway.

MFC after:	1 week
2013-04-09 20:21:35 +00:00
andrew
0e1ccb44c5 When building universe ensure the required worlds are finished before
starting the kernels. Before this the kernels would be built as part of the
last architecture universe target. There can cause problems when this world
finishes before the other worlds as the host compiler may be picked up
rather than the target compiler.

The solution is to add a target to build the universe kernels that depends
on all the world targets finishing. As we may not be building a world only
depend on it when MAKE_JUST_KERNELS is undefined.
2013-03-31 02:03:34 +00:00
marcel
05bf457ab4 Add the buildLINT convenience target, handy for build automation.
The automation can set TARGET_ARCH and TARGET and then make various
top-level targets, including buildLINT and buildkernel (with
KERNCONF=LINT). Previously there was no way to generate the LINT
kernel configuration without having to do something exceptionally
painful.
2012-11-03 20:43:12 +00:00
marcel
52e7fd7c54 Add support for bmake. This includes:
1.  Don't do upgrade_checks when using bmake. As long as we have WITH_BMAKE,
    there's a bootstrap complication in ths respect. Avoid it. Make the
    necessary changes to have upgrade_checks work wth bmake anyway.
2.  Remove the use of -E. It's not needed in our build because we use ?= for
    the respective variables, which means that we'll take the environment
    value (if any) anyway.
3.  Properly declare phony targets as phony as bmake is a lot smarter (and
    thus agressive) about build avoidance.
4.  Make sure CLEANFILES is complete and use it on .NOPATH. bmake is a lot
    smarter about build avoidance and should not find files we generate in
    the source tree. We should not have files in the repository we want to
    generate, but this is an easier way to cross this hurdle.
5.  Have behavior under bmake the same as it is under make with respect to
    halting when sub-commands fail. Add "set -e" to compound commands so
    that bmake is informed when sub-commands fail.
6.  Make sure crunchgen uses the same make as the rest of the build. This
    is important when the make utility isn't called make (but bmake for
    example).
7.  While here, add support for using MAKEOBJDIR to set the object tree
    location. It's the second alternative bmake looks for when determining
    the actual object directory (= .OBJDIR).

Submitted by:	Simon Gerraty <sjg@juniper.net>
Submitted by:	John Van Horne <jvanhorne@juniper.net>
2012-10-06 20:01:05 +00:00
obrien
2cda43d113 Not all Pmake derivatives silently handle empty shell output, so ensure there
is something for make(1) to consume.  Bmake gives output such as:
   "warning: Couldn't read shell's output for "/bin/sh -c true"
Note we parted from traditional Pmake behavior in r18864 / r18255.
2012-09-12 14:44:25 +00:00
gonzo
b501ab9dc9 Merging of projects/armv6, part 3
r238211:
Support TARGET_ARCH=armv6 and TARGET_ARCH=armv6eb

This adds a new TARGET_ARCH for building on ARM
processors that support the ARMv6K multiprocessor
extensions.  In particular, these processors have
better support for TLS and mutex operations.

This mostly touches a lot of Makefiles to extend
existing patterns for inferring CPUARCH from ARCH.
It also configures:
 * GCC to default to arm1176jz-s
 * GCC to predefine __FreeBSD_ARCH_armv6__
 * gas to default to ARM_ARCH_V6K
 * uname -p to return 'armv6'
 * make so that MACHINE_ARCH defaults to 'armv6'
It also changes a number of headers to use
the compiler __ARM_ARCH_XXX__ macros to configure
processor-specific support routines.

Submitted by:	Tim Kientzle <kientzle@freebsd.org>
2012-08-15 03:21:56 +00:00
obrien
e132be1d9e Add "hier" as an alternate spelling of "hierarchy" to match hier(9). 2012-07-03 06:41:00 +00:00
jmallett
4544b2987d Assume a big-endian default on MIPS and drop the "eb" suffix from MACHINE_ARCH.
This makes our naming scheme more closely match other systems and the
expectations of much third-party software.  MIPS builds which are little-endian
should require and exhibit no changes.  Big-endian TARGET_ARCHes must be
changed:
	From:		To:
	mipseb		mips
	mipsn32eb	mipsn32
	mips64eb	mips64

An entry has been added to UPDATING and some foot-shooting protection (complete
with warnings which should become errors in the near future) to the top-level
base system Makefile.
2012-03-29 02:54:35 +00:00
jmallett
f4fbc695fe Add a kernel-toolchains target like the toolchains target, but building only
the parts of the toolchain necessary to build kernels.
2012-03-13 00:38:49 +00:00
pluknet
e0d1bce11d delete-old does not have delete-old-libs dependency.
Reflect this in the comment.

PR:		conf/163993
Submitted by:	Eugen Konkov <kes-kes at yandex ru>
MFC after:	3 days
2012-02-16 14:08:14 +00:00
gjb
d19e8d9a37 Replace 'chflags' with 'file flags' in a comment, since 'chflags'
is a command, not a flag itself.

While here, wrap a line for readability.

Submitted by:		arundel
MFC after:		3 days
X-MFC-With:		227769, 227770
2011-11-20 20:05:47 +00:00
gjb
4cbcc15d99 Fix the note in r227769 to be less specific to the immutable flag.
Submitted by:		arundel
MFC after:		3 days
X-MFC-With:		r227769
2011-11-20 19:27:52 +00:00
gjb
46ca9e75dd Add a note to src/Makefile that explains that 'rm' runs twice because the
second invocation only needs to operate on files with the immutable flag
set.

Submitted by:		arundel (via private email) (original version)
Discussed on:		-toolchain@
MFC after:		3 days
2011-11-20 19:05:32 +00:00
ru
3fa3d79859 It's a bit odd, but "make update" in src/ can also update the ports/,
doc/, and now www/ trees, but only using the "cvsup" transport.

When "make update" is run using a tree's makefile, it can also use
"cvs" (except for www/) and "svn" (only src/).

Clean up documentation and code regarding "make update":

- Increase oddness by adding support for WWWSUPFILE and NO_WWWUPDATE to
  Makefile.inc1 (analogous to PORTSSUPFILE/NO_PORTSUPDATE and
  DOCSUPFILE/NO_DOCUPDATE; WWWSUPFILE already supported by www/Makefile).

- Document all trees that support CVS_UPDATE.

- Document all trees that support SUP_UPDATE.

- Document SVN_UPDATE.

- Document NO_WWWUPDATE.

- make.conf(5) mistakenly said that *SUPFILE* had defaults.

- Add an example entry for WWWSUPFILE.
2011-06-16 12:28:37 +00:00
attilio
96139278ce Disconnect sun4v architecture from the three.
Some files keep the SUN4V tags as a code reference, for the future,
if any rewamped sun4v support wants to be added again.

Reviewed by:	marius
Tested by:	sbruno
Approved by:	re
2011-05-14 01:53:38 +00:00
jhb
67e72142a1 Add the mipsn32eb TARGET_ARCH to the list of mips targets for the
XLRN32 kernel config.

Reviewed by:	imp, jmallet
2011-04-29 18:27:50 +00:00
bz
d47989ee77 If building (custom) FreeBSD images people tend to patch param.h. In case
this happens just before the build is started (within the same second)
CHECK_TIME actually triggers thinking param.h is in the future (see f_Xtime,
c_Xtime logi in find(1) sources for the details in !F_EXACTTIME case).
Using the -mtime -0s (seconds, rather than no unit) avoids this 1s race.

Submitted by:	ed (2009-05-03)
Reviewed by:	cperciva (2009-05-03), emaste
Tested by:	bz (for almost two years)
MFC after:	4 days
2011-04-12 02:07:23 +00:00
dougb
f272389b99 Update recommendation for mergemaster. The -a and -i options are exclusive.
PR:		docs/156271
Submitted by:	Fedor Dikarev <fedor.dikarev@gmail.com>
2011-04-10 03:53:06 +00:00
nwhitehorn
a8c9f18299 Improve the distributeworld target in Makefile.inc1 and update the release
infrastructure to use it. make distributeworld can now be used without
preparing its environment first and installs games into its distribution
using the regular make distribute logic instead of post-processing with
a script.

Also add two new targets, packageworld and packagekernel, that tar up the
results of distributeworld and distributekernel (also new), respectively.
2011-03-02 14:39:26 +00:00
jhb
e8017b8cea Fully honor KERNSRCDIR for 'make universe' if it is set.
MFC after:	1 week
2011-03-01 14:54:14 +00:00
jhb
5316147f1e - Add a new UNIVERSE_TARGET variable for 'make universe'. If it is set,
then that target is invoked for each architecture rather than the
  default action of building world and kernels for each architecture.
- Add a 'make toolchains' wrapper which uses UNIVERSE_TARGET to build
  toolchains for all architectures.
- Document JFLAG, MAKE_JUST_KERNELS, and MAKE_JUST_WORLDS variables for
  'make universe'.

Reviewed by:	bz
MFC after:	1 week
2011-02-10 18:54:52 +00:00
imp
c70bfd860a Setting TARGET and TARGET_ARCH needs to be done in _MAKE, not in the
TGTS rule as _MAKE is used elsewhere.  This should fix make world.
2011-02-02 23:59:24 +00:00
imp
2131e19013 Move the architecture guessing from Makefile.inc1 to Makefile. We
need to do this because variables specified on the command line
override those specified in the Makefile.  This is why we also moved
from TARGET to _TARGET in Makefile, and then set TARGET on the command
line when we fork a submake with Makefile.inc1.

This makes mips/mips work again, even without the workaround committed to
lib/libc/Makefile.
2011-01-31 15:17:47 +00:00
bz
ab3c671599 Back out r217734. [1]
Properly document what `make targets` is supposed to list to avoid
further confusion given the place the target sits. Should have happened
with r217125.

Requested by:	imp [1]
Reviewed by:	rwatson
2011-01-25 08:13:31 +00:00
bz
4bf4793433 For make tinderbox there is no need to print the extra commands.
MFC after:	5 days
2011-01-23 16:28:44 +00:00
bz
9eac5e09d6 Make make tinderbox work with MAKEOBJDIRPREFIX set (or in possibly other
combinations) by forcing FAILFILE into .CURDIR as we do for all other
universe output files. [1]  Similarly make FAILFILE start with "_." as well.

Reviewed by:	silence-on-src [1]
MFC after:	6 days
2011-01-22 23:16:44 +00:00
bz
199e86369e In make targets print the make variable TARGETS as we expect it rather
than the grammatically better sounding variant without the 'S'.  This
allows copy and paste and is less confusing.
2011-01-22 23:10:58 +00:00
bz
c94366e913 Properly document what the top-level make tinderbox does.
Reviewed by:	jmallett
MFC After:	3 days
X-MFC:		build.7 only
2011-01-22 22:57:28 +00:00
imp
61101fdbf7 Provide up-to-date estimates that are pessimal today... 2011-01-12 04:59:29 +00:00
imp
c2d8b7c75a Proving once again, I can't typo: fix a type. 2011-01-11 22:57:41 +00:00
imp
25020faf2e Minor improvements in the wording of a comment. Document tinderbox target. 2011-01-11 18:32:05 +00:00
imp
ec8aab4b2d make targets
This produces a list of currently supported targets.  Here "supported"
means "built in make universe" on the theory that those targets are
more supported than any that might work in 'make buildworld TARGET=x
TARGET_ARCH=y' since the latter are less tested.

Suggested by: rwatson
2011-01-07 20:36:27 +00:00
imp
54d5c7e86f Retire TARGET_ABI.
Implement MACHINE_ARCH=mips64e[lb] to build N64 images.  This replaces
MACHINE_ARCH=mipse[lb] TARGET_ABI=n64.

MACHINE_ARCH=mipsn32e[lb] has been added, but currently requires
WITHOUT_CDDL due to atomic issues in libzfs.  I've not investigated
this much, but implemented this to preserve as much of the TARGET_ABI
functionality that I could.  Since its presence doesn't affect the
working cases, I've kept it in for now.

Added mips64e[lb] to make universe, so more kernels build.

And I think this (finally) closes the curtain on the tbemd tree.
2011-01-07 20:26:33 +00:00
imp
192742df1e When TARGET_ARCH_${kernel} gets set, it is using the host's config,
not the one we build as part of make world.  This means that make
universe will fail if building on a too-old current or any stable
system prior to a few days ago in weird ways (parse errors from
shell).  This copes with these old systems in two ways:

(1) Works around the WARNING: issue by filtering all warnings that
    sneak onto stdout.

(2) if TARGET_ARCH_${kernel} winds up being empty, then we error out
    immediately with a semi-useful error message.  This usually comes from
    config not groking -m.

Ideally, we'd use a buildworld's config here, but that's tricky, so
I'll leave that detail to others to fix (it has to be done post make
world for the arch rather than at the top level makefile).  This
should make 'make universe' usable from recent 8-stable systems
(recent == last few months or so) for building -current.  They have
-m, but spewed warnings out stdout.  Older systems will now at least
get a firm error early rather than a confusing error late.
2011-01-03 22:48:01 +00:00
imp
c5439e9661 Redirect stderr from config to /dev/null. config -m is printing lots
of annoying warnings when dealing with arm.  The arm config files need
to be fixed, but this restricts the output to a more useful place.
2010-12-24 04:55:56 +00:00
nwhitehorn
58baed5a57 Reconnect arm to the universe build, and connect big-endian MIPS and ARM
and powerpc64 to universe for the first time. In general, provide
(slightly hacky) knowledge of multi-architecture TARGETs to universe as
well as the ability to distinguish the correct toolchain for a given
kernel using config -m.
2010-12-18 14:34:05 +00:00
jhb
4e3d1cfc31 Pass JFLAG as JFLAG from tinderbox to universe. This gives the same
semantics for JFLAG with tinderbox as for universe.  Previously doing
'make JFLAG=-j4 tinderbox' was equivalent to 'make -j4 universe'
(i.e. 4 worlds in parallel) rather than 'make JFLAG=-j4 universe'
(i.e. worlds in sequence, each built with -j4).

MFC after:	1 month
2010-12-16 15:27:13 +00:00
imp
554a219f6e Add mips back to universe 2010-11-13 22:38:33 +00:00
imp
c178b8695e Complete the integration of tbemd branch into head.
TARGET_BIG_ENDIAN is now completely dead, except where it was
originally supposed to be used (internally in the toolchain building).

TARGET_ARCH has changed in three cases:
(1) Little endian mips has changed to mipsel.
(2) Big endian mips has changed to mipseb.
(3) Big endian arm has changed to armeb.

Some additional changes are needed to make 'make universe' work on arm
and mips after this change, so those are commented out for now.

UPDATING information will be forthcoming.  Any remaining rough edges
will be hammered out in -current.
2010-11-10 06:39:49 +00:00
raj
ce1aea1edb Connect FDT infrastructure to the build system.
Reviewed by:	imp
Sponsored by:	The FreeBSD Foundation
2010-06-13 13:02:43 +00:00
dougb
69fc195c59 For those of us mere mortals who do not aspire to the lofty heights
of kernel hackery, add MAKE_JUST_WORLDS so that we can take part in
the 'make universe' goodnes without using unecessary time and resources.
2010-03-18 18:58:17 +00:00
imp
88d5aa8df2 Give make kernel-toolchain a one-liner here. Although documented in
build(7), many people look here for a quick reminder...
2010-03-03 21:08:44 +00:00
ed
0e18e3f232 Back out the change to Makefile made in r202628.
It was just a local modification to build the i386 and amd64 more
quickly.
2010-01-19 15:34:16 +00:00
ed
ec8fd67a3e Recommit r193732:
Remove __gnu89_inline.

  Now that we use C99 almost everywhere, just use C99-style in the pmap
  code. Since the pmap code is the only consumer of __gnu89_inline, remove
  it from cdefs.h as well. Because the flag was only introduced 17 months
  ago, I don't expect any problems.

  Reviewed by:    alc

It was backed out, because it prevented us from building kernels using a
7.x compiler. Now that most people use 8.x, there is nothing that holds
us back. Even if people run 7.x, they should be able to build a kernel
if they run `make kernel-toolchain' or `make buildworld' first.
2010-01-19 15:31:18 +00:00
bz
5467bb4869 Rather than using an extra variable, only call uname if really needed and
then directly assign the result.

Submitted by:	jmallett
MFC after:	24 days
X-MFC with:	r201815
2010-01-11 17:58:15 +00:00
bz
ee1cddf922 Use uname -m [1] and rename BUILD_ARCH to XMACHINE[2].
Submitted by:	nyan[1], imp[2]
MFC after:	27 days
X-MFC with:	r201815
2010-01-09 23:37:29 +00:00
bz
1af59610c9 To avoid hardcoding further kernel configuration names for
make universe, split the logic into two parts:
- 1st to build worlds and generate kernel configs like LINT.
- 2nd to build kernels for a given TARGET architecture correctly
  finding all newly generated configs, not knowing anything about
  LINT anymore. (*)

(*) If you know better/cleaner/... ways to do this, let me know.

Discussed on/with:	arch, jhb, rwatson
MFC after:		1 month
2010-01-08 19:01:50 +00:00
bz
0a11466281 Add a new world named 'mips' to our universe.
Discussed with:		imp
2009-04-01 17:11:50 +00:00
imp
6270d8e9fe Implement the xdev target. When you define XDEV=arch XDEV_ARCH=arch,
you can build the cross development tools and install them as
$XDEV-freebsd-xxx for each tool.  This allows one to use autoconf to
find the tools for cross building scenarios.
2009-03-13 07:23:58 +00:00
bz
455856ff06 Permit digits at the beginning and end of kernel config file names for
`make universe'. This catches a few more arm and, once enabled, mips
configs and permits having local configs named like NOINET6.

Reviewed by:	phk
MFC after:	4 weeks
2008-12-27 15:07:51 +00:00
alfred
4081b776af Provide a 'tinderbox' target that compiles enough of FreeBSD that
a developer can rest reasonably assured that the tinderbox will not
be broken.  This target leverages most of 'universe' but will exit
non-zero and output a summary at the end.

"make tinderbox"
2008-12-01 00:45:51 +00:00
des
315e1d3a3c Change the universe target to warn the user for every world or kernel that
fails.  The error message includes a reference to the relevant log file.

Approved by:	phk
MFC after:	1 week
2008-11-24 11:23:14 +00:00
bz
a786ca56c9 Back out rev. 1.352 (SVN rev 179842) as phk pointed out that
SRCCONF was omitted here to be able to build non standard trees
with universe as well.
2008-06-17 11:08:49 +00:00
bz
e772b82d0b For make universe, in addition to make.conf, also ignore a
src.conf with possibe non-default options.

Reviewed by:	ru
MFC after:	10 days
2008-06-17 09:06:46 +00:00
jb
e75a451fc0 Backout the change to remove sun4v.
Note that sun4v is currently broken on T2000 hardware so it's pretty
much a lame duck at this point.
2008-05-25 22:13:17 +00:00
jb
8ea302a3db Remove sun4v from the list of arches in 'make universe'. There has been
no active development on it for over a year now and it isn't
reliable under a simple buildworld. Developers can't be expected to
test code targeted for it.
2008-05-25 02:48:57 +00:00
jb
e78530f9ea Add a knob to allow just the kernels to be built during a 'make universe'.
This is useful when wanting to retry a broken build using NOCLEAN and the
buildworlds are known to have completed.
2008-05-23 04:20:59 +00:00
rwatson
b02f65b649 Mention -U and -ai arguments to mergemaster in a comment for the
general mergemaster line.

MFC after:	3 days
Suggested by:	Ben Laurie
2008-04-29 09:08:33 +00:00
pav
2b290549e3 Double up the necessary size of /usr/obj to 800MB
PR:		misc/99735
Reported by:	Philip M. Gollucci <pgollucci@p6m7g8.com>,
		Maxim Konovalov <maxim@macomnet.ru>
2008-03-31 13:32:55 +00:00
ru
771a69438e Add code that should catch the most common case when date/time is
set incorrectly.
2008-03-25 15:47:22 +00:00
jhb
b3bca4a1b7 Add a note pointing to build(7) for more info.
MFC after:	1 week
Reviewed by:	ru
2008-01-30 19:33:18 +00:00
imp
8b217e6eca We don't need to invent BSDMAKE. ${MAKE} is sufficient.
Submitted by: jmallet@
2007-12-13 00:08:02 +00:00
imp
aec3ebc791 Don't assume that make(1) is a bsd-like make program. It might not be. This
only matters in the early stages of bootstrapping, of course, but gnu make can't
handle bsd make Makefiles at all if they use any of the 'dot' directives, which
src/Makefile has in abudnance.
2007-12-11 20:00:55 +00:00
delphij
a7e0dd3928 Do not bail out for cleanworld target just because
chflags is failed.
2007-10-18 08:41:52 +00:00
des
5e9f952e4c Expose all of {check,delete}-old{,-dirs,-files,-libs}.
MFC after:	3 weeks
2007-05-16 08:46:35 +00:00
marcel
5f0f57215b Introduce a variable TARGETS that can be set on the make command line
and that controls which platforms are being built as part of a "make
universe". By default TARGETS is set to the 8 platforms currently
being built. This variable is useful for running or re-running a
"make universe" with only a selected set of platforms. This makes the
universe target slightly more useful in cases the universe is limited
to a developer's scope or objectives. For example, when a universe
failed for a particular platform and fixes need to be tested for that
particular platform then a developer can restart the universe for
only that platform, even if the initial universe is still building
other platforms.
2007-04-02 21:32:44 +00:00
ru
6ea883cd0b Add arm to universe. 2006-11-28 01:03:29 +00:00
jb
a8f497ff90 Remove the NO_CTF option. It would have been required to support
DTrace.
2006-11-21 08:25:28 +00:00
jb
7f880f15f4 When building an upgraded make, don't worry about processing it for
use with DTrace because the normal buildworld will do that when the
tools are built.
2006-11-01 09:05:40 +00:00
jb
c0e6d5e665 Add sun4v to the 'universe'. 2006-10-16 22:18:59 +00:00
ru
1274e5767f In "make universe", utilize simplified cross-build synopsis,
"make TARGET=<machine> build*", now that it actually works.

Prompted by:	imp
2006-09-08 10:13:15 +00:00
imp
8734146d90 Per weak consensus on this topic, remove suggestion to set
HISTORICAL_MAKE_WORLD from the text that's output.  This was committed
against the previous consensus.  Leave the documentation in this file
as a compromose.  The HISTORICAL_MAKE_WORLD knob is intentionally
obfuscated and we only trust people smart enough to read the Makefile
to use it.  All others have no business using it due to its danger,
unless DESTDIR is set.

Dissentors: grog, obrien, trhodes
2006-06-22 16:52:53 +00:00
obrien
39e51502f7 Note a short-cut in the build procedure. 2006-06-21 09:53:42 +00:00
trhodes
20e391b445 Simply running ``make world'' will bomb unless you dig up the
undocumented HISTORICAL_MAKE_WORLD variable and set it.  Note it
here so the blow up will not really be a surprise to people who
read.

Link the buildingworld chapter of our handbook in the README
while I'm here.
2006-06-07 03:33:48 +00:00
imp
f22f333d75 Create a new target 'buildenvvars'. This target reports the build
environment for cross building (the same one you'd get interactively
in make buildenv).  This cannot be a simple

        make -f Makefile.inc1 -V WMAKEENV

because in PATH is not set correctly unless one takes a trip through
the Makefile/Makefile.inc1 indirection, the logic of which is too
large to reproduce outside of Makefiles.
2006-06-06 16:24:54 +00:00
netchild
e14fcb8fd5 Connect the kernel subsystem API documentation generation framework to
the build infrastructure: "make doxygen"

Changes to the man pages will be made when some defaults are revisited.

Requested by:	gnn
2006-05-26 18:10:06 +00:00
jhb
aca3e09a0c Disconnect Alpha from 'make universe'. 2006-05-11 18:54:16 +00:00
ru
86d485cdba Add the new "showconfig" target that displays build configuration.
Suggested by:	phk
2006-03-18 14:30:23 +00:00
ru
d90987744c Make ${SUBDIR_TARGETS} work at the uppermost level as well. 2006-03-15 14:22:32 +00:00
yar
8d6d9efea2 Do not discard the current value of __MAKE_CONF when testing
whether MAKEOBJDIRPREFIX is set at a wrong place.

Reviewed by:	ru
MFC after:	3 days
2006-03-01 13:07:17 +00:00
ru
208069ffa8 Fix a bug in previous revision: skip LINT if it exists, not NOTES
(the source for LINT), as I initially intended.
2005-11-28 11:14:36 +00:00
ru
f97bcd3b19 universe: don't attempt to compile DEFAULTS and don't compile LINT twice. 2005-11-28 11:03:59 +00:00
netchild
f78772bbe4 Add delete-old and delete-old-libs targets:
- removes obsolete files/dirs or libraries.
  - works in interactive (default) and batch mode
  - respects DISTDIR
  - documented in UPDATING and build(7)

The head of the file ObsoleteFiles.inc contains instructions how to add
obsolete files/dirs/libs to the list. Obviously one should add obsolete
files to this list, when he removes a file/dir/lib from the basesystem.

Additionally add check-old target:
  - allows re@ to check if a file on the obsolete list resurfaces

Design goals:
  - allows full control by the user (default interactive mode)
  - possibility of scripted removal of obsolete files (batch mode)
  - opt-in removal of files (explicit list of files)
  - seperate removal of libs (2 delete targets)

Important design decissions:
  - structured list of files to remove instead of a plain text file:
    * allows to remove additional files if a NO_foo knob is specified
      without the need to change the targets (no NO_foo knob is respected
      yet)
  - not using mtree like NetBSD does:
    * mtree doesn't has an interactive mode

Discussed on:		arch (long ago), current (this year)
Additional input from:	re (hrs)
Approved by:		mentor (joerg)
2005-07-23 14:23:30 +00:00
ru
f5828b013e - Embed the "buildkernels" target into the "universe" target so that
the "make -n universe" output looks more builder (human) friendly.

- Wrap the "universe" target into a ".if make(universe)"; it's only
  intended to be called directly so it should be safe to do it.
2005-07-19 11:21:14 +00:00
ru
e10a9fc385 Make the `distrib-dirs' target official and working properly
when cross-building (installing).  (This is useful for NFS
installing world/kernel to another architecture machine.)
2005-07-15 14:38:54 +00:00
ru
73ab2fc036 Provide 32-bit runtime support on amd64 as a separate distribution, lib32.
Prodded by:	obrien
Nodded by:	peter
Approved by:	re
2005-06-16 18:16:14 +00:00
harti
13d684fd15 Repo-copy tools/regression/usr.bin/make to tools/build/make_check
and adjust the path in the Makefile for the upgrade_checks target.
These checks are really feature upgrade checks that should be fast
and just find out whether we need to build a new make before
proceeding with other targets like buildworld. This makes the
place free for a real regression test suite in the old place.
2005-03-02 12:33:23 +00:00
ru
5d9bc16368 Added the convenience "distribution" target which calls the
target of the same name from src/etc/Makefile with a proper
environment, suitable to be used during upgrades and cross-
builds.
2005-02-27 12:11:35 +00:00
ru
dc4d1e599e Added the "buildenv" target, for developers only!
CAVEAT: if you run tcsh(1) from within this target, this will
reset your PATH making this target mostly useless.  Careful!

Submitted by:	jmg, ru
2005-02-26 22:02:18 +00:00
ru
c1a820195c NOSHARED -> NO_SHARED 2004-12-21 09:59:45 +00:00
ru
cec60429bb Start the dreaded NOFOO -> NO_FOO conversion.
OK'ed by:	core
2004-12-21 08:47:35 +00:00
ru
4b04260bb8 Previous revision didn't fix all cases. For example,
testing for variables that are always defined (e.g.,
"make -V CC") would still print a false warning.  Fix
this by only passing a submake the MAKEOBJDIRPREFIX=*
argument if it was present.  As a result, we loose
the check for -DMAKEOBJDIRPREFIX, or an esoteric
"MAKEOBJDIRPREFIX = foo" (with embedded spaces), but
these are unorthodox enough to not care about them.

The make(1) bug mentioned in the previous revision
was just fixed in make/main.c,v 1.109.
2004-12-16 19:55:57 +00:00
marcel
86608beae6 Unbreak the MAKEOBJDIRPREFIX variable check by avoiding bugs in make(1).
When make flags are passed to make in the environment, the string is
chopped up in an (argc,argv) vector. This happens in brk_string() and
the chopped up string is stored in static buffer. When this includes
something like "-V BINMAKE", then a pointer into the static buffer is
put on the variables list for evaluation later. However, brk_string()
is used for more than just chopping up the MAKEFLAGS env. variable, so
it's very likely that the static buffer is clobbered. In fact, this is
exactly what happens.
The result is that _MAKEOBJDIRPREFIX gets assigned whatever garbage
the child make happens to emit, causing the test to fail. Like this:

pluto2% cd /usr/src
pluto2% make -V BINMAKE
"/q/6.x/src/Makefile", line 94: MAKEOBJDIRPREFIX can only be set in environment, not as a global (in /etc/make.conf) or command-line variable.
pluto2% make -dv -V BINMAKE | & grep _MAKEOBJDIRPREFIX
Global:_MAKEOBJDIRPREFIX = }

The fix is to not use MAKEFLAGS for this, but simple pass the flags
as arguments. Ideally make(1) should be fixed but that's beyond the
scope of my attention span.

This fixes release.
2004-12-13 00:49:52 +00:00
harti
c90efa2b2f Fix builds with a read-only directory and a make upgrade. This is done
by forcing the creation of an object directory for the make regression
tests. Let make handle the tracking of the dependency and installation
of test_shell script.

Submitted by:	ru
2004-12-07 14:41:16 +00:00
peter
0555f41924 Convert tools/lib32/build.sh into world connectable hooks. This still
rates pretty high on the "hack!" scale, but it works for me.  Adding
-DWANT_LIB32 to the world build command line, or 'WANT_LIB32=yes' to
/etc/make.conf will include the 32 bit libraries with the build.

I have not made this default behavior.  Cross compiling this stuff is an
adventure I have not investigated.

This is still a WIP.  We needed this at work so that we could install from
a readonly obj tree - lib32/build.sh wasn't up to that.
2004-11-06 03:14:26 +00:00
ru
d7592a9bb7 Fixed MAKEOBJDIRPREFIX variable type check in case the env(1)
binary is not in PATH, as is the case with installworld, etc.
2004-10-18 17:47:31 +00:00
ru
d4d76490aa My take at improving the universe: allow the worlds to be
built in parallel.  Examples:

make universe
	Build worlds sequentially, each world sequentially.

make universe JFLAG=-j4
	Build worlds sequentially, each world in parallel.

make -j4 universe
make -j4 universe JFLAG=-j2
	Build four worlds in parallel, each world will be
	built in parallel too.  World parallelization is
	set to four in the first synopsis, and to two in
	the second.

make -j4 universe JFLAG=-B
	Build worlds in parallel, each world sequentially.

("world" == buildworld followed by buildkernels.)

Prayers:	obrien, phk
2004-08-18 07:17:01 +00:00
ru
75f12cc1b8 Moved the MAKEOBJDIRPREFIX check from Makefile.inc1 to Makefile,
to suppress warnings with installworld and distributeworld when
env(1) cannot be found in the PATH.
2004-08-18 06:49:56 +00:00
harti
91ae96e9ab Make make recurse into sub-directories and sub-makes when given
two -n flags.  If only one -n flag is given the old behaviour
is retained (POLA).  In order to make this working for installworld
change the IMAKEENV in this case so that the tools are found
(we have no temporary installation environment in this case).

Submitted by:	ru (IMAKEENV part)
2004-08-09 11:38:41 +00:00
kensmith
fdb6f08c0e The doc team reworked the section of the handbook describing how to
rebuild things, further discouraging 'make world'.  The title of
that section is now changed...
2004-07-23 21:21:34 +00:00
markm
b538ed4a41 Rename a preposterously long name with one that might look a bit
more professional. While here, write a few lines of explanatory
text to explain what its for.

Discussed with:	rwatson
With hat:	core
2004-07-18 18:55:31 +00:00
obrien
6670049bcf Add an "out" to the now required BS of defining DESTDIR. 2004-07-18 01:19:33 +00:00
marcel
7beb6d42ce Properly terminate a quoted string in the previous commit. Oddly
enough this only seems to cause problems with -jX so went unnoticed
until now.
2004-07-17 20:57:37 +00:00
marcel
dec36cc079 As per discussions on current@, protect unsuspecting users from
trying to upgrade their system with make world instead of following
the preferred and suggested sequence of commands. The fact remains
that make world does not upgrade the kernel.
Allow make world when DESTDIR has been specified, including when
DESTDIR specifies the root file system. Otherwise, print a useful
warning and fail.

Reviewed, tested and scrutinized by: gad@
2004-07-16 02:51:28 +00:00
phk
98f388939d Add a JFLAG which can be used to speed up universe:
make universe JFLAG=-j12
2004-07-09 13:55:50 +00:00
des
d6c0324b5f Add a kernel-toolchain target which only builds the bits required to build
a kernel.  This is essentially the same as the toolchain target, except
that it does not build headers and libraries.

Submitted by:	ru
2004-04-13 13:42:01 +00:00
ru
da8ebfd558 Added the `toolchain' top-level target, which builds enough of
buildworld, up to and including libraries, except for actually
building the world.

Requested by:	many
2004-03-24 08:26:22 +00:00
ru
c2d12bfbee Protect shell expansions. 2004-03-02 14:32:23 +00:00
johan
bed3e7f235 Add amd64 to universe.
Approved by:	peter
2004-02-29 13:07:05 +00:00
gad
fd20be1aef Change the 'realclean' target name to be 'cleanworld', to match other
targets like buildworld, installworld.

Suggested by:	obrien
2004-02-20 02:10:35 +00:00
gad
bf55d649fc Improvements on the 'make realclean' target. Some are style improvements,
but the biggest issue is that there are situatons when
${.OBJDIR} == ${.SRCDIR}, and in those situations the previous version
would happily remove all your /usr/src while it was cleaning out the objects.
Not that *you* would be happy about it...  Thanks to bde for immediately
noticing this serious possibility.

More improvements will be made to this target, but I wanted to commit this
safer version right now, before anyone lost their /usr/src due to it.

Reviewed by:	bde
MFC after:	10 days
2004-02-19 21:09:58 +00:00
gad
80b725fa15 Add a 'realclean' target, which simply and quickly removes everything
that was built in previous 'make buildworld' and 'make buildkernel'.  The
target knows enough to run a 'chflags -R 0' and a second 'rm' if the first
'rm' ran into any errors while removing files.

Suggested by:	email with Richard Coleman Re: upcoming 64b-time_t changes.
Reviewed by:	imp, marcel, and others on -hackers
MFC after:	1 week
2004-02-16 20:18:25 +00:00
peter
84e2c4c55b Put on some factor 30+ bikeshed repellent and export the internal
Makefile.inc1 underscore targets with a big warning that they are
intentionally undocumented, subject to change without notice and
might poison your dog etc.  If you don't know what they are, then they
are not meant for you to use.

I've added these by hand to so many many trees that I've lost count.  I
find them rather useful.
2003-12-09 02:08:19 +00:00
kris
9ae8412ffe Don't allow the 'make' target (which rebuilds make for bootstrapping)
to become confused by a file called 'make' in /usr/src

Submitted by:	ru
2003-11-07 08:36:55 +00:00
ru
0f6892a7db Retired the "most" and "installmost" targets -- they just
do not have a chance to work nowadays as we have a lot of
internal libraries in lib/.

Discussed with:	marcel, wollman
2003-10-04 18:53:38 +00:00
ru
dfb52d2c75 Cosmetics: folded BITGTS into TGTS. 2003-08-30 13:33:41 +00:00
marcel
7eec2ccb23 Limit testing for an up-to-date version of make(1) to the world and
buildworld targets by default, but allow it to be done for all user
targets by introducing a boolean option, named ALWAYS_CHECK_MAKE.

This change is by no means perfect and I don't even want to claim
this to be a solution. It does however address the fact that not
everybody likes to see make(1) rebuilt simply because the regression
test failed for some reason or other, including pilot error. It
therefore serves the purpose of keeping the crowd happy until we
have something better or simply reached a compromise.

The reasons for changing the default behaviour are:
o  It avoids a negative, possibly non-intuitive option,
o  It's according to POLA and fond of feet,
o  Only buildworld is documented to do its best to be
   successful at reasonably cost.

Reviewed by: gad, imp, obrien, peter
2003-08-28 04:03:13 +00:00
ru
7ba06f3d15 - Don't print "elf" before printing "make world" (aout support has been
removed).

- Avoid using printf(1) where a simple shell's built-in echo is enough.
2003-08-06 11:06:38 +00:00
ru
1563c405c7 The `mk' target is long dead. 2003-07-20 12:38:29 +00:00
ru
5dff75f40c Use an up-to-date make binary in the upgrade_checks target if
one is already available.  This avoids sometimes unnecessary
step of attempting to rebuild the make binary again which may
fail at all if, for example, one has removed his /usr/include
before doing an installworld (to keep /usr/include tidied up).

Pointed out by:	kris, marcel
2003-07-19 23:17:08 +00:00
ru
1b9c1552b4 Don't hardcore PATH into BINMAKE; the latter should only be
comprised of the path to a make(1) binary (possibly the one
built by the "make" target in this Makefile), and a path to
a fresh share/mk.  The idea is to allow "make release" pick
up the right "make" binary, if one exists.

This fixes release.5 I broke with the last commit here; the
second PATH here was overriding the right one from WMAKEENV
while rebuilding the "build-tools" for crunched binaries.
2003-07-04 17:35:26 +00:00
ru
240df1e4a7 Fixed style bugs related to parentheses in Makefile.inc1.
Submitted by:	bde

Fixed nearby bug: propagate the root Makefile's idea of
the appropriate "make" binary down to release/Makefile.
2003-07-04 14:27:06 +00:00
ru
4e21fcc762 Do the upgrade checks quietly. 2003-06-22 21:56:22 +00:00
simokawa
c2d986d0e3 Allow installkernel.debug and reinstallkernel.debug. 2003-06-22 10:01:03 +00:00
imp
9c53d2269f Kill upgrade target docs. It too is stale.
Submitted by: ru
2003-04-03 05:34:36 +00:00
imp
e22dff07de Kill aout to elf upgrade path. From an old comment in the makefile:
# If -DWANT_AOUT is specified, a `make world' with OBJFORMAT=elf will
# update the legacy support for aout. This includes all libraries, ld.so
# and boot objects. This part of build should be regarded as
# deprecated and you should _not_ expect to be able to do this past the
# release of 4.0. You have exactly one major release to move entirely
# to elf.

Now that we're past 5.0, these aren't needed at all anymore and it is
well past its freshness date.
2003-04-03 05:28:09 +00:00