From ba757048075f83540cf9cf496bfdd6492a6e9d37 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Rafa=C5=82=20D=C5=82ugo=C5=82=C4=99cki?= Date: Mon, 15 Jul 2013 08:41:37 +0200 Subject: [PATCH] vlp-7 Added automatic doxygen documentation generation. --- Makefile.am | 32 ++++++++++++++++++++++++++------ configure.ac | 7 +++++++ 2 files changed, 33 insertions(+), 6 deletions(-) diff --git a/Makefile.am b/Makefile.am index cd2e1ee..cc1d19c 100644 --- a/Makefile.am +++ b/Makefile.am @@ -133,17 +133,12 @@ clean-loghelp-extra: rm -f bin/modules/loghelp rm -f bin/loghelp -all-local: +all-local: doxyfile.stamp test -d bin/modules || mkdir bin/modules ln -fs ../logedit bin/modules/ ln -fs ../loggraph bin/modules/ ln -fs ../loghelp bin/modules/ ln -fs ../lognet bin/modules/ - -CLEANFILES = \ - %.o \ - %.bak \ - %~ clean-am: \ clean-loggraph-extra \ @@ -155,4 +150,29 @@ clean-am: \ clean-loghelp-extra rm -rf bin/modules +CLEANFILES = \ + %.o \ + %.bak \ + %~ \ + doxyfile.stamp + +if HAVE_DOXYGEN + +directory = $(top_srcdir)/doc/man/man3/ + +dist_man_MANS = $(directory)/man_page_1.3 $(directory)/man_page_2.3 +$(directory)/man_page_1.3: doxyfile.stamp +$(directory)/man_page_2.3: doxyfile.stamp + +doxyfile.stamp: + $(DOXYGEN) Doxyfile + echo Timestamp > doxyfile.stamp + +#all-local: doxyfile.stamp + +clean-local: + rm -rf $(top_srcdir)/doc/man + +endif + dist_noinst_SCRIPTS = autogen.sh diff --git a/configure.ac b/configure.ac index e7397f6..65e94cf 100644 --- a/configure.ac +++ b/configure.ac @@ -35,5 +35,12 @@ AC_ARG_WITH([moc-compiler-dir], [MOCDIR='/usr/bin']) AC_SUBST([MOCDIR]) +AC_CHECK_PROGS([DOXYGEN], [doxygen]) +if test -z "$DOXYGEN"; + then AC_MSG_WARN([Doxygen not found - continuing without Doxygen support]) +fi + +AM_CONDITIONAL([HAVE_DOXYGEN], [test -n "$DOXYGEN"]) +AM_COND_IF([HAVE_DOXYGEN], [AC_CONFIG_FILES([Doxyfile])]) AC_OUTPUT -- 2.30.2