From bc2e1d155f4531eef5564639b50d3252af873273 Mon Sep 17 00:00:00 2001 From: Michal Privoznik Date: Tue, 1 Nov 2022 10:07:59 +0100 Subject: configure.ac: Fix variable escaping for newer autoconf When using autoconf macros, one has to be careful because some arguments as they may need additional escaping. In this particular case, the second argument passed to AC_DEFINE_UNQUOTED() is problematic as autoconf runs it in a subshell resulting in 'yes' being interpreted as a name of a variable instead of literal "yes" string. Putting quotes around it lets shell know we want string comparison. This problem was noticed with autoconf-2.71. Signed-off-by: Michal Privoznik Acked-by: Tom Hromatka Signed-off-by: Paul Moore --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index dfe3db0..f2f6862 100644 --- a/configure.ac +++ b/configure.ac @@ -120,7 +120,7 @@ AS_IF([test "$enable_python" = yes], [ ]) AM_CONDITIONAL([ENABLE_PYTHON], [test "$enable_python" = yes]) AC_DEFINE_UNQUOTED([ENABLE_PYTHON], - [$(test "$enable_python" = yes && echo 1 || echo 0)], + [$(test "$enable_python" = "yes" && echo 1 || echo 0)], [Python bindings build flag.]) AC_CHECK_TOOL(GPERF, gperf) -- cgit v1.2.1