Doesn't work though :(. Building docs is very fragile...
At least, if docbook is present, distcheck passes now.
# TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
# PERFORMANCE OF THIS SOFTWARE.
-DOCSRC=@DOCSRC@
SUBDIRS=fontconfig fc-case fc-lang fc-glyphname src \
fc-cache fc-cat fc-list fc-match fc-pattern fc-query fc-scan \
- conf.d $(DOCSRC) test
+ conf.d test
+if ENABLE_DOCS
+SUBDIRS += doc
+DIST_SUBDIRS = $(SUBDIRS)
+else
+DIST_SUBDIRS = $(SUBDIRS) doc
+endif
AUTOMAKE_OPTIONS = dist-bzip2
ACLOCAL_AMFLAGS = -I m4
cp -a $(distdir) $(distdir).orig
$(RM) -r $(distdir).orig/debian
+DISTCHECK_CONFIGURE_FLAGS =
+
-include $(top_srcdir)/git.mk
AM_CONDITIONAL(ENABLE_DOCS, test "x$enable_docs" = xyes)
if test "x$enable_docs" = xyes; then
- DOCSRC="doc"
tmp=funcs.$$
cat $srcdir/doc/*.fncs | awk '
/^@TITLE@/ { if (!done) { printf ("%s\n", $2); done = 1; } }
echo DOCMAN3 $DOCMAN3
rm -f $tmp
else
- DOCSRC=""
DOCMAN3=""
fi
-
-AC_SUBST(DOCSRC)
AC_SUBST(DOCMAN3)
clean-local:
$(RM) -r $(HTML_DIR) devel-man
[ "x$(builddir)" != "x$(srcdir)" ] && $(RM) $(builddir)/*.sgml || :
+dist-local-check-docs-enabled:
+ @true
else
htmldoc_DATA += $(srcdir)/$(HTML_DIR)/*
all-local:
clean-local:
+dist-local-check-docs-enabled:
+ @echo "*** --enable-man must be used in order to make dist"
+ @false
endif
+# force doc rebulid after configure
+dist-hook-local: dist-local-check-docs-enabled
+
-include $(top_srcdir)/git.mk