summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Schaffter <peter@schaffter.ca>2014-10-19 13:12:19 -0400
committerPeter Schaffter <peter@schaffter.ca>2014-10-19 13:12:19 -0400
commite5ab613ed052900138e489207a2d60f482969aa3 (patch)
tree5ec8e2a7f533a2dfbe3afb7cc1abacda55a0e5ad
parent4834f90f52d90209a4136505ee35c211babd8230 (diff)
downloadgroff-git-e5ab613ed052900138e489207a2d60f482969aa3.tar.gz
Ensure pre-built html (mom) docs are always installed
-rw-r--r--Makefile.in6
-rw-r--r--contrib/mom/Makefile.sub9
-rw-r--r--m4/groff.m49
3 files changed, 20 insertions, 4 deletions
diff --git a/Makefile.in b/Makefile.in
index 4dd82ef39..16543ae9b 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -282,6 +282,10 @@ make_htmlexamples=@make_htmlexamples@
make_install_htmlexamples=@make_install_htmlexamples@
make_uninstall_htmlexamples=@make_uninstall_htmlexamples@
+# However, there may always be some prebuild HTML documentation
+make_install_shipped_htmldoc=@make_install_shipped_htmldoc@
+make_uninstall_shipped_htmldoc=@make_uninstall_shipped_htmldoc@
+
# The configure script also checks whether all necessary utility programs
# for pdfroff are available -- only then we can build PDF documentation.
make_pdfdoc=@make_pdfdoc@
@@ -575,6 +579,8 @@ MDEFINES=\
"make_htmlexamples=$(make_htmlexamples)" \
"make_install_htmlexamples=$(make_install_htmlexamples)" \
"make_uninstall_htmlexamples=$(make_uninstall_htmlexamples)" \
+ "make_install_shipped_htmldoc=$(make_install_shipped_htmldoc)" \
+ "make_uninstall_shipped_htmldoc=$(make_uninstall_shipped_htmldoc)" \
"make_pdfdoc=$(make_pdfdoc)" \
"make_install_pdfdoc=$(make_install_pdfdoc)" \
"make_uninstall_pdfdoc=$(make_uninstall_pdfdoc)" \
diff --git a/contrib/mom/Makefile.sub b/contrib/mom/Makefile.sub
index 04fc50113..020fc9fe3 100644
--- a/contrib/mom/Makefile.sub
+++ b/contrib/mom/Makefile.sub
@@ -134,7 +134,7 @@ examples/stamp:
touch $@
install_data: install_always \
- $(make_install_pdfdoc) $(make_install_htmldoc) \
+ $(make_install_pdfdoc) $(make_install_shipped_htmldoc) \
$(make_install_examples)
install_always: stamp-strip $(NORMALFILES)
@@ -151,7 +151,7 @@ install_always: stamp-strip $(NORMALFILES)
install_pdfdoc:
# Since this uses examples/, it's in install_pdfexamples
-install_htmldoc: install_always $(HTMLDOCFILES)
+install_shipped_htmldoc: install_always $(HTMLDOCFILES)
-test -d $(DESTDIR)$(htmldocdir)/mom \
|| $(mkinstalldirs) $(DESTDIR)$(htmldocdir)/mom
for f in $(HTMLDOCFILES_); do \
@@ -160,6 +160,7 @@ install_htmldoc: install_always $(HTMLDOCFILES)
$(DESTDIR)$(htmldocdir)/mom/$$f; \
done
+
install_examples: install_examples_always $(make_install_pdfexamples)
install_examples_always: $(EXAMPLEFILES)
@@ -192,7 +193,7 @@ stamp-strip: $(STRIPFILES)
touch $@
uninstall_sub: uninstall_always \
- $(make_uninstall_pdfdoc) $(make_uninstall_htmldoc) \
+ $(make_uninstall_pdfdoc) $(make_uninstall_shipped_htmldoc) \
$(make_uninstall_examples)
uninstall_always:
@@ -203,7 +204,7 @@ uninstall_always:
uninstall_pdfdoc: uninstall_always
# Since that used examples/, it's in uninstall_pdfexamples
-uninstall_htmldoc: uninstall_always
+uninstall_shipped_htmldoc: uninstall_always
-for f in $(HTMLDOCFILES_); do \
$(RM) $(DESTDIR)$(htmldocdir)/mom/$$f; \
done
diff --git a/m4/groff.m4 b/m4/groff.m4
index 502e10853..10b93d819 100644
--- a/m4/groff.m4
+++ b/m4/groff.m4
@@ -109,6 +109,13 @@ AC_DEFUN([GROFF_DOC_CHECK],
AC_MSG_WARN([Invalid `--with-doc' argument:] $i)
done
fi
+ if test $docadd_html = yes; then
+ make_install_shipped_htmldoc=install_shipped_htmldoc
+ make_uninstall_shipped_htmldoc=uninstall_shipped_htmldoc
+ else
+ make_install_shipped_htmldoc=
+ make_uninstall_shipped_htmldoc=
+ fi
if test $docadd_other = yes; then
make_otherdoc=otherdoc
make_install_otherdoc=install_otherdoc
@@ -128,6 +135,8 @@ AC_DEFUN([GROFF_DOC_CHECK],
make_uninstall_examples=
fi
AC_SUBST([doc_dist_target_ok])
+ AC_SUBST([make_install_shipped_htmldoc])
+ AC_SUBST([make_uninstall_shipped_htmldoc])
AC_SUBST([make_otherdoc])
AC_SUBST([make_install_otherdoc])
AC_SUBST([make_uninstall_otherdoc])