[Cmake] Trouble with string match
John Biddiscombe
jbiddiscombe at skippingmouse.co.uk
Thu, 5 Feb 2004 11:23:15 -0000
Hi all,
I'm passing a number into a macro and do this
IF("${VERSION}" MATCHES "\\d")
do something,
but if the version is actaully not numeric (ie a tag name from CVS), I want
to do something else. The string match "regex" doesn't seem to work
if I do
IF("${VERSION}" MATCHES "1")
it passes
but
IF("${VERSION}" MATCHES \\d)
with the string "1" passed in, it fails.
Any ideas?
thanks
JB