diff --git a/tools/tools/tinderbox/tinderbox.1 b/tools/tools/tinderbox/tinderbox.1 index 4b34506be915..b5546cff01ac 100644 --- a/tools/tools/tinderbox/tinderbox.1 +++ b/tools/tools/tinderbox/tinderbox.1 @@ -27,7 +27,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 24, 2004 +.Dd March 15, 2004 .Dt TINDERBOX 1 .Os .Sh NAME @@ -285,6 +285,12 @@ if a patch was specified. .It NOPORTS .Va YES .El +.Pp +Except for +.Va CFLAGS +and +.Va COPTFLAGS , +none of these variables may be overridden by command-line arguments. .Sh SEE ALSO .Xr cvs 1 , .Xr make 1 , diff --git a/tools/tools/tinderbox/tinderbox.pl b/tools/tools/tinderbox/tinderbox.pl index 55f25b7a5c24..24e10a231284 100644 --- a/tools/tools/tinderbox/tinderbox.pl +++ b/tools/tools/tinderbox/tinderbox.pl @@ -485,13 +485,11 @@ MAIN:{ 'TARGET' => $machine, 'TARGET_ARCH' => $arch, - - 'CFLAGS' => "-O -pipe", ); # Kernel-specific variables if ($cmds{'generic'} || $cmds{'lint'} || $cmds{'release'}) { - $ENV{'COPTFLAGS'} = "-O -pipe"; + # None at the moment } # Release-specific variables @@ -523,6 +521,18 @@ MAIN:{ $ENV{$key} = $userenv{$key}; } } + + # Defaults for overridable variables + if (!exists($ENV{'CFLAGS'})) { + $ENV{'CFLAGS'} = "-O -pipe"; + } + if ($cmds{'generic'} || $cmds{'lint'} || $cmds{'release'}) { + if (!exists($ENV{'COPTFLAGS'})) { + $ENV{'COPTFLAGS'} = "-O -pipe"; + } + } + + # List the environment when verbose if ($verbose && $verbose > 1) { foreach my $key (sort(keys(%ENV))) { message("$key=$ENV{$key}\n");