GNU bug report logs - #7990
Quoting problem with AM_COND_IF

Previous Next

Package: automake;

Reported by: Dennis Schridde <devurandom <at> gmx.net>

Date: Sat, 5 Feb 2011 19:46:02 UTC

Severity: normal

Tags: notabug

Done: Stefano Lattarini <stefano.lattarini <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Eric Blake <eblake <at> redhat.com>
To: Dennis Schridde <devurandom <at> gmx.net>
Cc: 7990 <at> debbugs.gnu.org
Subject: bug#7990: Quoting problem with AM_COND_IF
Date: Sat, 05 Feb 2011 13:49:09 -0700
[Message part 1 (text/plain, inline)]
On 02/05/2011 12:26 PM, Dennis Schridde wrote:
> AM_CONDITIONAL([CONDITION],[test -x /tmp])
> AS_IF([test -x /bin],
>     AM_COND_IF([CONDITION],,
>         AC_MSG_ERROR([comma separated, message])
>     )
> )

The quoting problem is with you, not with AM_COND_IF.  This should be
written:

AS_IF([test -x /bin],
      [AM_COND_IF([CONDITION],,
           [AC_MSG_ERROR([comma separated, message])
      ])
])

Remember the quoting rule of thumb - every argument to a macro should be
inside a single layer of quotes unless you really want the macro
expanded first (which is rare)

-- 
Eric Blake   eblake <at> redhat.com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

[signature.asc (application/pgp-signature, attachment)]

This bug report was last modified 14 years and 108 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.