doc: hook up doxygen to generate the public API documentation
[platform/upstream/libinput.git] / doc / Makefile.am
1 if HAVE_DOXYGEN
2
3 noinst_DATA = html/index.html
4
5 header_files = \
6         $(top_srcdir)/src/libinput.h
7
8 html/index.html: libinput.doxygen $(header_files)
9         $(AM_V_GEN)$(DOXYGEN) $<
10
11 clean-local:
12         $(AM_V_at)rm -rf html
13
14 doc_src= $(shell find html -type f -printf "html/%P\n" 2>/dev/null)
15 EXTRA_DIST = $(builddir)/html/index.html $(doc_src)
16
17 endif
18
19 # make sure doc was built before running dist
20 dist-hook:
21         @test -f $(distdir)/html/index.html || (\
22                 echo "******************************************************" && \
23                 echo "Couldn't find documentation files, refusing make dist." && \
24                 echo "Install doxygen to build documentation for tarball." && \
25                 echo "******************************************************" && \
26                 test )