[Vm-dev] Make question
piumarta at speakeasy.net
piumarta at speakeasy.net
Tue Sep 5 12:14:19 UTC 2006
> It seems that no variation of
>
> ifneq (,$(wildcard locationA/foo.locA))
> @echo foo.locA exists
> else
> @echo foo.locA does NOT exist
> endif
>
> works properly due to the way the "failure" case needs to be specified
> (i.e., the result of the $wildcard function is not just "empty").
(I tried for five minutes and couldn't make it generate anything but the file name or an empty string. But I'm not running MinGW so that's not really helpful...)
Why not just invert the sense of the test and compare for what you know is a valid result of the$wildcard?
ifeq (locationA/foo.locA,$(wildcard locationA/foo.locA))
@echo foo.locA exists
else
@echo foo.locA does NOT exist
endif
Cheers,
Ian
More information about the Vm-dev
mailing list