svn commit: r359046 - head/share/mk

Brooks Davis brooks at freebsd.org
Wed Mar 18 16:53:00 UTC 2020


On Wed, Mar 18, 2020 at 12:29:24PM +0900, Hiroki Sato wrote:
> Brooks Davis <brooks at FreeBSD.org> wrote
>   in <202003171817.02HIHWdY035423 at repo.freebsd.org>:
> 
> br> Author: brooks
> br> Date: Tue Mar 17 18:17:32 2020
> br> New Revision: 359046
> br> URL: https://svnweb.freebsd.org/changeset/base/359046
> br>
> br> Log:
> br>   Support SUBDIR.${MK_FOO}.${MK_BAR} expresssions.
> br>
> br>   This allows simplification of Makefiles where some SUBDIR entries depend
> br>   on two things (e.g. something that depends on C++ and some other knob).
> 
>  Just my two cents, but SUBDIR.${MK_FOO:M${MK_BAR}:M${MK_BAZ}}= dir
>  should do the trick.  I am not sure how many variables we need to
>  support in practice, adding ".yes.yes..." in bsd.subdir.mk looks less
>  flexible to me.

IMO that's lousy from a readability perspective.  It's remotely
conceivable that supporting three variables might make sense, but more
seems vanishingly unlikely and even so, it's trivial to add more cases.

-- Brooks
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 455 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/svn-src-head/attachments/20200318/1fdc6187/attachment.sig>


More information about the svn-src-head mailing list