[master] 8d38f05 Hook changes.rst into build system

Tollef Fog Heen tfheen at varnish-cache.org
Wed May 11 12:06:11 CEST 2011


commit 8d38f05c4876b09d457480e24cb8e60424c8e48c
Author: Tollef Fog Heen <tfheen at varnish-software.com>
Date:   Wed May 11 08:52:13 2011 +0200

    Hook changes.rst into build system

diff --git a/configure.ac b/configure.ac
index f401b45..616d411 100644
--- a/configure.ac
+++ b/configure.ac
@@ -56,6 +56,12 @@ if test "x$RST2MAN" = "xno"; then
 fi
 AM_CONDITIONAL(HAVE_RST2MAN,[test "x$RST2MAN" != "xno"])
 
+AC_CHECK_PROGS(RST2HTML, [rst2html rst2html.py], "no")
+if test "x$RST2HTML" = "xno"; then
+   AC_MSG_WARN([rst2html not found – not building changelog])
+fi
+AM_CONDITIONAL(HAVE_RST2HTML,[test "x$RST2HTML" != "xno"])
+
 # Checks for libraries.
 save_LIBS="${LIBS}"
 LIBS=""
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 9774622..58d9dc7 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -44,7 +44,8 @@ all: ${CHANGELOGS}
 endif
 
 EXTRA_DIST = ${CHANGELOGS} ${XML} \
-	changes.css changes-html.xsl
+	changes.css changes-html.xsl \
+	changes.rst changes.html
 
 CLEANFILES = ${CHANGELOGS}
 SUFFIXES = .xml .html
@@ -59,6 +60,17 @@ else
 	@false
 endif
 
+changes.html: changes.rst
+if HAVE_RST2HTML
+	${RST2HTML} $? $@
+else
+	@echo "========================================"
+	@echo "You need rst2html installed to make dist"
+	@echo "========================================"
+	@false
+endif
+
+
 ${CHANGELOGS}: changes-html.xsl
 
 SUBDIRS = sphinx



More information about the varnish-commit mailing list