On Fri, Oct 28, 2005 at 03:28:45PM -0400, Paul D. Smith wrote: > %% "Boucher, Jean" <[EMAIL PROTECTED]> writes: > > bj> Also, one of the situation I'm trying to test for is the empty > bj> string (in my previous example, say Y=`'), which I believe I can't > bj> test in this manner: > > bj> ifeq ($(var),$(filter $(var),X `')) > bj> ... > bj> endif > > Nope, you can't do that. Hm. That's tricky, because the empty string > in GNU make means "false". > > You can use $(if ...)... a bit strange with an if function inside an > ifeq, but it would work. You'd have to write it specially: using the > GMSL version John created I don't think will work because the value > you're comparing it to is itself false. > > Something like this would work I think (untested): > > ifeq ($(var),$(if $(var),$(filter $(var),X),$(var)))
You may be able to get by with this if conditional 1 and conditional 2 are mutually exclusive or Action is not sensitive to multiple execution. 1) define Action the stuff you want to do endef ifeq (conditional 1) $(Action) endif ifeq (conditional 2) $(Action) endif Ken _______________________________________________ Help-make mailing list [email protected] http://lists.gnu.org/mailman/listinfo/help-make
