]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
m4: want_bsdauth.m4 - Modernize m4 syntax
authorKarl Fleischmann <karl.fleischmann@open-xchange.com>
Tue, 14 Jun 2022 08:15:07 +0000 (10:15 +0200)
committerKarl Fleischmann <karl.fleischmann@open-xchange.com>
Mon, 4 Jul 2022 09:43:26 +0000 (11:43 +0200)
m4/want_bsdauth.m4

index cd64c8de0825447e23db69c110a567d0c24ebcda..a4149dfe72c113ce64180cbdac0f05b7880cc5f2 100644 (file)
@@ -1,18 +1,19 @@
 AC_DEFUN([DOVECOT_WANT_BSDAUTH], [
   have_bsdauth=no
-  if test $want_bsdauth != no; then
-          AC_CHECK_FUNC(auth_userokay, [
-                  AC_DEFINE(PASSDB_BSDAUTH,, [Build with BSD authentication support])
-                  have_bsdauth=yes
-          ], [
-            if test $want_bsdauth = yes; then
-              AC_ERROR([Can't build with BSD authentication support: auth_userokay() not found])
-            fi
-          ])
-  fi
-  if test $have_bsdauth = no; then
+
+  AS_IF([test "$want_bsdauth" != "no"], [
+    AC_CHECK_FUNC(auth_userokay, [
+      AC_DEFINE(PASSDB_BSDAUTH,, [Build with BSD authentication support])
+      have_bsdauth=yes
+    ], [
+      AS_IF([test "$want_bsdauth" = "yes"], [
+        AC_ERROR([Can't build with BSD authentication support: auth_userokay() not found])
+      ])
+    ])
+  ])
+  AS_IF([test "$have_bsdauth" = "no"], [
     not_passdb="$not_passdb bsdauth"
-  else
+  ], [
     passdb="$passdb bsdauth"
-  fi
+  ])
 ])