summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRan Benita <ran234@gmail.com>2017-07-28 18:19:40 +0300
committerRan Benita <ran234@gmail.com>2017-07-31 15:55:48 +0300
commit4983dbcf43fd6b3a924b4fe06997f385f1e008fc (patch)
tree77fed5eff4eb0bc54df263dabfcd96bc991a2666
parent0a19267f309485df0889b67be118274cbb94c7f6 (diff)
downloadxorg-lib-libxkbcommon-4983dbcf43fd6b3a924b4fe06997f385f1e008fc.tar.gz
build: change doxygen target to be properly dependency-based
This hackery (thanks libinput) is clearer and more precise than the previous hackery. Signed-off-by: Ran Benita <ran234@gmail.com>
-rw-r--r--Makefile.am27
-rw-r--r--doc/.gitignore1
-rw-r--r--doc/Doxyfile.in12
3 files changed, 21 insertions, 19 deletions
diff --git a/Makefile.am b/Makefile.am
index a22bd7a..d46481b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -149,18 +149,29 @@ src/xkbcomp/parser.h: $(top_builddir)/src/$(am__dirstamp) $(top_builddir)/src/xk
if ENABLE_DOCS
if HAVE_DOXYGEN
-doc: doc/stamp-doxygen
+doxygen_input = \
+ $(top_srcdir)/README.md \
+ $(top_srcdir)/doc/quick-guide.md \
+ $(top_srcdir)/doc/compat.md \
+ $(top_srcdir)/xkbcommon/xkbcommon.h \
+ $(top_srcdir)/xkbcommon/xkbcommon-names.h \
+ $(top_srcdir)/xkbcommon/xkbcommon-x11.h \
+ $(top_srcdir)/xkbcommon/xkbcommon-compose.h
+
+doc/html: doc/Doxyfile $(doxygen_input)
+ $(AM_V_GEN)(\
+ cat $<; \
+ echo "INPUT = $(doxygen_input)"; \
+ echo "OUTPUT_DIRECTORY = $(abs_top_builddir)/doc"; \
+ ) | $(DOXYGEN) -
+clean-doxygen:
+ rm -rf doc/html
+
+doc: doc/html
clean-doc: clean-doxygen
all-local:: doc
clean-local:: clean-doc
-doc/stamp-doxygen: $(top_srcdir)/xkbcommon/*.h
- $(AM_V_GEN)(cd $(top_srcdir) && $(DOXYGEN) $(abs_top_builddir)/doc/Doxyfile)
- touch $@
-
-clean-doxygen:
- rm -rf doc/html doc/stamp-doxygen
-
install-data-local:: doc
$(MKDIR_P) $(DESTDIR)$(htmldir)
$(INSTALL_DATA) doc/html/* $(DESTDIR)$(htmldir)
diff --git a/doc/.gitignore b/doc/.gitignore
index 3e70371..63b767d 100644
--- a/doc/.gitignore
+++ b/doc/.gitignore
@@ -1,3 +1,2 @@
Doxyfile
html/
-stamp-doxygen
diff --git a/doc/Doxyfile.in b/doc/Doxyfile.in
index 36d517d..04a2991 100644
--- a/doc/Doxyfile.in
+++ b/doc/Doxyfile.in
@@ -2,8 +2,6 @@ PROJECT_NAME = @PACKAGE_NAME@
PROJECT_NUMBER = @PACKAGE_VERSION@
-OUTPUT_DIRECTORY = @abs_top_builddir@/doc
-
BRIEF_MEMBER_DESC = NO
JAVADOC_AUTOBRIEF = YES
@@ -18,13 +16,7 @@ QUIET = YES
WARN_IF_UNDOCUMENTED = NO
-INPUT = README.md \
- doc/quick-guide.md \
- doc/compat.md \
- xkbcommon/xkbcommon.h \
- xkbcommon/xkbcommon-names.h \
- xkbcommon/xkbcommon-x11.h \
- xkbcommon/xkbcommon-compose.h \
+INPUT = @INPUT@
FILE_PATTERNS = *.c \
*.h
@@ -40,7 +32,7 @@ ALPHABETICAL_INDEX = NO
IGNORE_PREFIX = xkb_ \
XKB_
-HTML_EXTRA_STYLESHEET = doc/doxygen-extra.css
+HTML_EXTRA_STYLESHEET = @abs_top_srcdir@/doc/doxygen-extra.css
HTML_TIMESTAMP = NO