doc: Configure --disable-* should disable build as well as install.
authorMatt Birkholz <puck@birchwood-abbey.net>
Fri, 12 Dec 2014 17:01:53 +0000 (10:01 -0700)
committerMatt Birkholz <puck@birchwood-abbey.net>
Fri, 12 Dec 2014 17:01:53 +0000 (10:01 -0700)
Add a TARGETS variable to collect ENabled targets, like INST_TARGETS.

doc/configure.ac
doc/make-common.in

index 36b234bd8bb6944914d3c5413d957d9ab744ac1b..8af9794fae10dcd8be3238711e957ab443cb25f2 100644 (file)
@@ -38,6 +38,7 @@ then
     INSTALL="${INSTALL} --preserve-timestamps"
 fi
 
+TARGETS=
 INST_TARGETS=
 
 AC_ARG_ENABLE([html],
@@ -49,6 +50,7 @@ elif test "${enable_html}" = "no"; then
 else
     htmldir="${enable_html}"
 fi
+test "${htmldir}" = "" || TARGETS="${TARGETS} \$(TARGET_ROOT)/index.html"
 test "${htmldir}" = "" || INST_TARGETS="${INST_TARGETS} install-html"
 AC_SUBST([htmldir])
 
@@ -61,6 +63,7 @@ elif test "${enable_pdf}" = "no"; then
 else
     pdfdir="${enable_pdf}"
 fi
+test "${pdfdir}" = "" || TARGETS="${TARGETS} \$(TARGET_ROOT).pdf"
 test "${pdfdir}" = "" || INST_TARGETS="${INST_TARGETS} install-pdf"
 AC_SUBST([pdfdir])
 
@@ -73,9 +76,11 @@ elif test "${enable_ps}" = "no"; then
 else
     psdir="${enable_ps}"
 fi
+test "${psdir}" = "" || TARGETS="${TARGETS} \$(TARGET_ROOT).ps"
 test "${psdir}" = "" || INST_TARGETS="${INST_TARGETS} install-ps"
 AC_SUBST([psdir])
 
+AC_SUBST([TARGETS])
 AC_SUBST([INST_TARGETS])
 
 AC_CONFIG_FILES([
index 0a689eee5edb552a7bb3242ae5d54141fd25fbfa..81f64b945a200d509137ec43ad1f6fbfb84b4925 100644 (file)
@@ -60,6 +60,7 @@ htmldir = @htmldir@
 pdfdir = @pdfdir@
 psdir = @psdir@
 
+TARGETS = @TARGETS@
 INST_TARGETS = @INST_TARGETS@
 
 INFO_TARGET = $(TARGET_ROOT).info
@@ -70,7 +71,7 @@ PS_TARGET = $(TARGET_ROOT).ps
 
 TEX_OPTIONS = --quiet $(EXTRA_TEX_OPTIONS)
 
-all: $(INFO_TARGET) $(HTML_TARGET)/index.html $(PDF_TARGET) $(PS_TARGET)
+all: $(INFO_TARGET) $(TARGETS)
 
 $(INFO_TARGET): $(SOURCES)
        rm -f $(INFO_TARGET)*