From 2c833326fdd83039999b5563eb9f621ff57e3bf5 Mon Sep 17 00:00:00 2001 From: Gaetan Nadon Date: Tue, 9 Mar 2010 10:13:22 -0500 Subject: doc: Specify minimum xmlto version to XORG_WITH_DOXYGEN Adds an optional parameter to XORG_WITH_DOXYGEN to enforce a minimum version needed like the asciidoc version check. Reviewed-by: Dan Nicholson Signed-off-by: Gaetan Nadon --- xorg-macros.m4.in | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) (limited to 'xorg-macros.m4.in') diff --git a/xorg-macros.m4.in b/xorg-macros.m4.in index cdff61d..fd9e259 100644 --- a/xorg-macros.m4.in +++ b/xorg-macros.m4.in @@ -434,8 +434,8 @@ fi]) AM_CONDITIONAL([HAVE_ASCIIDOC], [test "$have_asciidoc" = yes]) ]) # XORG_WITH_ASCIIDOC -# XORG_WITH_DOXYGEN -# ---------------- +# XORG_WITH_DOXYGEN([MIN-VERSION]) +# -------------------------------- # Minimum version: 1.5.0 # # Documentation tools are not always available on all platforms and sometimes @@ -482,8 +482,22 @@ elif test "x$use_doxygen" = x"no" ; then else AC_MSG_ERROR([--with-doxygen expects 'yes' or 'no']) fi +m4_ifval([$1], +[if test "$have_doxygen" = yes; then + # scrape the doxygen version + AC_MSG_CHECKING([the doxygen version]) + doxygen_version=`$DOXYGEN --version 2>/dev/null` + AC_MSG_RESULT([$doxygen_version]) + AS_VERSION_COMPARE([$doxygen_version], [$1], + [if test "x$use_doxygen" = xauto; then + AC_MSG_WARN([doxygen version $doxygen_version found, but $1 needed]) + have_doxygen=no + else + AC_MSG_ERROR([doxygen version $doxygen_version found, but $1 needed]) + fi]) +fi]) AM_CONDITIONAL([HAVE_DOXYGEN], [test "$have_doxygen" = yes]) -]) # XORG_CHECK_DOXYGEN +]) # XORG_WITH_DOXYGEN # XORG_WITH_GROFF # ---------------- -- cgit v1.2.3