On 06/03/2010 04:11 PM, Bruno Haible wrote: > Hi Eric, > > Thanks for the help, but... > >>> AM_CONDITIONAL([LIBUNISTRING_]AS_TR_CPP([$1]), [true]) >> >> AM_CONDITIONAL([LIBUNISTRING_]AS_TR_CPP([[$1]]), [true]) > > This does not work either: > > $ autoconf > configure.ac:11: error: AC_SUBST: `LIBUNISTRING_undesired substitution_TRUE' is not a valid shell variable name > aclocal.m4:125: AM_CONDITIONAL is expanded from... > configure.ac:6: MYCOND is expanded from... > configure.ac:11: the top level > > I get the impression that AS_TR_CPP is removing more quotes than it should. Indeed. I'll look into fixing that. But that means you can't quite use it on unsafe names in the meantime. On the other hand, why not use: AM_CONDITIONAL(AS_TR_CPP([[LIBUNISTRING_$1]]), [true]) such that you are using the LIBUNISTRING_ prefix as part of any potential macro name, and can thus have more assurance that the user's macros are not going to interfere unless they created macros that interfered with your namespace. -- Eric Blake eblake@xxxxxxxxxx +1-801-349-2682 Libvirt virtualization library http://libvirt.org
Attachment:
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Autoconf mailing list Autoconf@xxxxxxx http://lists.gnu.org/mailman/listinfo/autoconf