[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: VCS=(yes|always)

From: Yavor Doganov
Subject: Re: VCS=(yes|always)
Date: Sun, 27 Jan 2008 09:54:30 +0200
User-agent: Wanderlust/2.15.1 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.7 (Sanjō) APEL/10.6 Emacs/22.1 (i486-pc-linux-gnu) MULE/5.0 (SAKAKI) (gNewSense GNU/Linux)

Калоян Доганов wrote:
> I understand your reasons, but this solution defeats a basic
> convention.

I don't see how, when the build behaves exactly as expected.

> One would expect that $(CVS) is always invoked with $(CVSOPTS) so
> modifying $(CVSOPTS) will affect all $(CVS) invocations.

There is no way to modify CVSOPTS from the command line directly, so
how this variable is used within the makefile is an internal matter.
We should use it in the recipes only when it's useful, like anything

> +ifeq (yes,$(subst always,yes,$(VCS)))

This is not a reliable way to catch variable values from the command
line.  Furthermore, this will trigger the rule when VCS=yes which is
useless and slow.  Now it's bearable, but when there are 300 files?

> +       ($(CVS) $(CVSOPTS) add $$file ; exit 0) ; done

Since CVSOPTS will always expand to the empty string here, no matter
what, I still don't see the point.  The conditional for this target is
evaluated at the beginning, when make reads the makefile, and since it
is always false when VCS is not "yes" or "always" (with your patch),
the variables are not assigned values at all.  This rule is a black
hole for make when the conditional is not met.  So you may as well
substitute it with the empty string, like it is now.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]