From: Timo Sirainen Date: Thu, 8 Dec 2016 00:23:52 +0000 (+0900) Subject: configure: Moved pandoc check to m4/dovecot.m4 X-Git-Tag: 2.3.0.rc1~2463 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=97745d12bd9e2b7ba4003ae747f3bd1e030ac357;p=thirdparty%2Fdovecot%2Fcore.git configure: Moved pandoc check to m4/dovecot.m4 --- diff --git a/configure.ac b/configure.ac index a42c366393..35d77a120b 100644 --- a/configure.ac +++ b/configure.ac @@ -818,17 +818,7 @@ LDFLAGS="\$(NOPLUGIN_LDFLAGS) $LDFLAGS" AC_SUBST(NOPLUGIN_LDFLAGS) DC_CC_WRAPPER - -AC_ARG_VAR(PANDOC, [Path to pandoc program]) - -# Optional tool for making documentation -AC_CHECK_PROGS(PANDOC, [pandoc], [true]) - -if test "$PANDOC" = "true"; then - if test ! -e README; then - AC_MSG_ERROR([Cannot produce documentation without pandoc]) - fi -fi +DC_PANDOC if test "$docdir" = ""; then dnl docdir supported only by autoconf v2.59c and later diff --git a/m4/dovecot.m4 b/m4/dovecot.m4 index 471fb27d92..5fce9c3bb9 100644 --- a/m4/dovecot.m4 +++ b/m4/dovecot.m4 @@ -169,3 +169,16 @@ EOF fi fi ]) + +AC_DEFUN([DC_PANDOC], [ + AC_ARG_VAR(PANDOC, [Path to pandoc program]) + + # Optional tool for making documentation + AC_CHECK_PROGS(PANDOC, [pandoc], [true]) + + if test "$PANDOC" = "true"; then + if test ! -e README; then + AC_MSG_ERROR([Cannot produce documentation without pandoc - disable with PANDOC=false ./configure]) + fi + fi +])