Make xsltproc optional

Fix Bug 23863 - xcb still checks for xsltproc:
    https://bugs.freedesktop.org/show_bug.cgi?id=23863

xsltproc is used to generate the optional html page for `check` results,
only. So, it's not a hard build dependency.

Additionally, use yes/no instead of true/false in the HTML_CHECK_RESULT
variable for consistent output after a configure run.

Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
This commit is contained in:
Daniel Martin 2012-12-31 11:57:49 +01:00
parent 0289348f2c
commit dd01db570c
2 changed files with 6 additions and 8 deletions

View File

@ -27,15 +27,12 @@ AC_LIBTOOL_WIN32_DLL
AC_PROG_LIBTOOL AC_PROG_LIBTOOL
AC_PROG_CC AC_PROG_CC
AC_PATH_PROG(XSLTPROC, xsltproc, no) XSLTPROC=no
if test "$XSLTPROC" = "no"; then HTML_CHECK_RESULT=no
AC_MSG_ERROR([XCB requires xsltproc.])
fi
HTML_CHECK_RESULT=false
if test x"$HAVE_CHECK" = xyes; then if test x"$HAVE_CHECK" = xyes; then
AC_PATH_PROG(XSLTPROC, xsltproc, no)
if test x"$XSLTPROC" != xno; then if test x"$XSLTPROC" != xno; then
HTML_CHECK_RESULT=true HTML_CHECK_RESULT=yes
fi fi
fi fi
AC_SUBST(HTML_CHECK_RESULT) AC_SUBST(HTML_CHECK_RESULT)
@ -258,6 +255,7 @@ echo ""
echo " Configuration" echo " Configuration"
echo " XDM support.........: ${have_xdmcp}" echo " XDM support.........: ${have_xdmcp}"
echo " Build unit tests....: ${HAVE_CHECK}" echo " Build unit tests....: ${HAVE_CHECK}"
echo " with html results.: ${HTML_CHECK_RESULT}"
echo " XCB buffer size.....: ${xcb_queue_buffer_size}" echo " XCB buffer size.....: ${xcb_queue_buffer_size}"
echo "" echo ""
echo " X11 extensions" echo " X11 extensions"

View File

@ -14,7 +14,7 @@ check_all_SOURCES = check_all.c check_suites.h check_public.c
check-local: check-TESTS check-local: check-TESTS
$(RM) CheckLog.html $(RM) CheckLog.html
if test x$(HTML_CHECK_RESULT) = xtrue; then \ if test x$(HTML_CHECK_RESULT) = xyes; then \
$(XSLTPROC) $(srcdir)/CheckLog.xsl CheckLog*.xml > CheckLog.html; \ $(XSLTPROC) $(srcdir)/CheckLog.xsl CheckLog*.xml > CheckLog.html; \
else \ else \
touch CheckLog.html; \ touch CheckLog.html; \