[PATCH 5/6] Merge doc/Makefile.am into Makefile.am
David Herrmann
dh.herrmann at gmail.com
Sun Sep 1 08:45:08 PDT 2013
no-subdir-objects is deprecated and future automake releases will enable
subdir-objects automatically. So try merging sub-makefiles into the
main-makefile.
Signed-off-by: David Herrmann <dh.herrmann at gmail.com>
---
Makefile.am | 44 ++++++++++++++++++++++++++++++++++++++++++--
configure.ac | 1 -
doc/Makefile.am | 25 -------------------------
doc/libevdev.doxygen.in | 6 +++---
4 files changed, 45 insertions(+), 31 deletions(-)
delete mode 100644 doc/Makefile.am
diff --git a/Makefile.am b/Makefile.am
index f549076..93b1efa 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -8,9 +8,10 @@ PRINT_DIRECTORY_FLAGS_0=--no-print-directory
PRINT_DIRECTORY_FLAGS_=$(PRINT_DIRECTORY_FLAGS_$(AM_DEFAULT_VERBOSITY))
AM_MAKEFLAGS = $(PRINT_DIRECTORY_FLAGS_$(V))
AM_CPPFLAGS = $(GCC_CFLAGS) $(GCOV_CFLAGS) -I$(top_srcdir) -I$(top_srcdir)/libevdev
-SUBDIRS = doc test
+SUBDIRS = test
lib_LTLIBRARIES =
noinst_PROGRAMS =
+dist_noinst_DATA =
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libevdev.pc
@@ -18,6 +19,7 @@ pkgconfig_DATA = libevdev.pc
EXTRA_DIST = libevdev.pc.in
CLEANFILES =
BUILT_SOURCES =
+TPHONY =
#
# libevdev/ build rules
@@ -56,7 +58,7 @@ CLEANFILES += event-names.h
BUILT_SOURCES += event-names.h
# gcov leaves it's mess in this directory too
-clean-local:
+clean-local-libevdev:
@rm -f libevdev/*.gcno
#
@@ -67,3 +69,41 @@ noinst_PROGRAMS += libevdev-events
libevdev_events_SOURCES = tools/libevdev-events.c
libevdev_events_LDADD = libevdev.la $(GCOV_LDFLAGS)
+
+#
+# doc/ build rules
+#
+
+if HAVE_DOXYGEN
+all-local: doxygen
+
+doxygen: doc/libevdev.doxygen
+ doxygen $<
+
+clean-local-doc:
+ rm -rf doc/html
+
+TPHONY += doxygen
+
+doc_src= $(shell find doc/html -name "*" -printf "doc/html/%P\n")
+EXTRA_DIST += $(doc_src) doc/libevdev.doxygen doc/libevdev.css
+endif
+
+dist_noinst_DATA += doc/libevdev.doxygen.in
+
+# make sure doc was built before running dist
+dist-hook:
+ @test -f $(distdir)/doc/html/index.html || (\
+ echo "******************************************************" && \
+ echo "Couldn't find documentation files, refusing make dist." && \
+ echo "Install doxygen to build documentation for tarball." && \
+ echo "******************************************************" && \
+ test )
+
+#
+# global rules
+#
+
+clean-local: clean-local-doc clean-local-libevdev
+
+.PHONY: $(TPHONY)
diff --git a/configure.ac b/configure.ac
index f3d867c..2ee15c0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -73,7 +73,6 @@ AC_SUBST([GCOV_LDFLAGS])
AC_MSG_RESULT([$enable_gcov])
AC_CONFIG_FILES([Makefile
- doc/Makefile
doc/libevdev.doxygen
test/Makefile
libevdev.pc])
diff --git a/doc/Makefile.am b/doc/Makefile.am
deleted file mode 100644
index 3fbd0ed..0000000
--- a/doc/Makefile.am
+++ /dev/null
@@ -1,25 +0,0 @@
-if HAVE_DOXYGEN
-all-local: doxygen
-
-doxygen: libevdev.doxygen
- doxygen $<
-
-clean-local:
- rm -rf html
-
-.PHONY: doxygen
-
-doc_src= $(shell find html -name "*" -printf "html/%P\n")
-EXTRA_DIST = $(doc_src) libevdev.doxygen libevdev.css
-endif
-
-dist_noinst_DATA = libevdev.doxygen.in
-
-# make sure doc was built before running dist
-dist-hook:
- @test -f $(distdir)/html/index.html || (\
- echo "******************************************************" && \
- echo "Couldn't find documentation files, refusing make dist." && \
- echo "Install doxygen to build documentation for tarball." && \
- echo "******************************************************" && \
- test )
diff --git a/doc/libevdev.doxygen.in b/doc/libevdev.doxygen.in
index fc5d7bb..c0e0885 100644
--- a/doc/libevdev.doxygen.in
+++ b/doc/libevdev.doxygen.in
@@ -652,8 +652,8 @@ WARN_LOGFILE =
# directories like "/usr/src/myproject". Separate the files or directories
# with spaces.
-INPUT = @top_srcdir@/libevdev/libevdev.h \
- @top_srcdir@/libevdev/libevdev-uinput.h
+INPUT = @srcdir@/libevdev/libevdev.h \
+ @srcdir@/libevdev/libevdev-uinput.h
# This tag can be used to specify the character encoding of the source files
# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is
@@ -914,7 +914,7 @@ HTML_STYLESHEET =
# robust against future updates. Doxygen will copy the style sheet file to
# the output directory.
-HTML_EXTRA_STYLESHEET = @srcdir@/libevdev.css
+HTML_EXTRA_STYLESHEET = @srcdir@/doc/libevdev.css
# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or
# other source files which should be copied to the HTML output directory. Note
--
1.8.4
More information about the Input-tools
mailing list