svn commit: r392209 - in head/devel: . p5-Minilla

Alexey Dokuchaev danfe at FreeBSD.org
Fri Jul 17 06:19:40 UTC 2015


On Thu, Jul 16, 2015 at 10:14:31PM -0700, Adam Weinberger wrote:
> I'd just like to mention PR 191273, which suggesting adding a new depends
> macro that registers a BUILD_ and RUN_DEPENDS.
> 
> 	BUILDANDRUN_DEPENDS=	foo:...
> (Or something. I'm terrible at naming things, but the concept/patch is
> there.)

Personally I think this is slightly over-engineered; I guess I'm not firmly
against it, but see no value in such macro for myself.

> By way of examples, a huge percentage of Perl modules rely on :=, and many
> of them perform impressive manoeuvres to assign
> 	RUN_DEPENDS:=	${BUILD_DEPENDS}
> 	BUILD_DEPENDS+=	???
> or my favorite
> 	BUILD_DEPENDS=	foo:...
> 	RUN_DEPENDS:=	${BUILD_DEPENDS:Nfoo*}

Again, I don't see the problem.  Do your rdeps exactly equal to bdeps?  If
yes, use :=.  Minor differences can be compensated with a trick, as long as
it's readable and intention (logic) is clear.  If things go further south
then you're probably better off with another variable or two.  Use common
sense, Luke! ;-)  Goes without saying you need to check and test, bla-bla.

> The fact that not even the PHB was clear on whether := was correct suggests
> that there is a problem that can use a solution.

PHB was (and is) quite clear; and there's nothing technically wrong in :=
when it being used correctly.  The problem here is mostly with people who
not (or do not want to) know their tools well enough, so := is considered
(with a certain merit) dangerous (read: easy to misuse) by some folks.

I don't want to argue is it really that dangerous, or should we encourage
it or not.  I find this feature valuable, I know when to use it, and I do
not like people telling me NOT to use it because there might be idiots^W
people that do not understand make(1) internals out there.

./danfe


More information about the svn-ports-head mailing list