Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 12 Jul 2010 09:59:33 +0400
From:      Ruslan Ermilov <ru@FreeBSD.org>
To:        Garrett Cooper <gcooper@FreeBSD.org>
Cc:        hackers@FreeBSD.org
Subject:   Re: [patch] SUBDIR_OVERRIDE `optimization'
Message-ID:  <20100712055933.GA3885@edoofus.dev.vega.ru>
In-Reply-To: <AANLkTim_UM_An_i81IfGZ0q0Y5cLFGpnWoUcTqlj9ODm@mail.gmail.com>
References:  <AANLkTiknaqqXyq3DoDXahbieessXZNIJUsryKbxI2DJJ@mail.gmail.com> <AANLkTim_UM_An_i81IfGZ0q0Y5cLFGpnWoUcTqlj9ODm@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Jul 09, 2010 at 07:56:37AM -0700, Garrett Cooper wrote:
> (Let's try this again with the right email address)
>     Something simple that I noticed a while back when I was reviewing
> the Makefile.inc1 code. The SUBDIR_OVERRIDE code is executed after the
> conditional feature checks, which sets the value of SUBDIRS to the
> user defined value. So instead of going through the conditionals, one
> could just cut to the chase and set SUBDIRS to SUBDIRS_OVERRIDE,
> otherwise detect the conditional directories to include in
> Makefile.inc1.
> Thanks!
> -Garrett
> 
> Index: Makefile.inc1
> ===================================================================
> --- Makefile.inc1	(revision 209684)
> +++ Makefile.inc1	(working copy)
> @@ -41,6 +41,9 @@
>  # use that new version.  And the new (dynamically-linked) /bin/sh
>  # will expect to find appropriate libraries in /lib and /libexec.
>  #
> +.if defined(SUBDIR_OVERRIDE)
> +SUBDIR=		${SUBDIR_OVERRIDE}
> +.else
>  SUBDIR=	share/info lib libexec
>  SUBDIR+=bin
>  .if ${MK_GAMES} != "no"
> @@ -79,8 +82,6 @@
>  .endif
>  .endfor
> 
> -.if defined(SUBDIR_OVERRIDE)
> -SUBDIR=		${SUBDIR_OVERRIDE}
>  .endif
> 
>  .if defined(NOCLEAN)

SUBDIR_OVERRIDE is mainly for FreeBSD src/ builders (to quickly
check with "buildworld" a particular bit of a tree), and is thus
rarely used, so this change would be an optimization for the
uncommon case.  Having said that, I don't mind if you commit it,
if you like.


Cheers,
-- 
Ruslan Ermilov
ru@FreeBSD.org
FreeBSD committer



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