src_test_libdbuspolicy1_method_LDADD = $(CYNARA_LIBS) \
src/libinternal.a
+
+if ENABLE_DOXYGEN
+
+CLEANFILES += documentation
+
+all-local:: doxygen.stamp
+
+doxygen.stamp:: doxygen.cfg
+ doxygen $<
+ echo Timestamp > $@
+
+install-data-local::
+ $(MKDIR_P) $(DESTDIR)/${docdir}
+ cp -r documentation/* $(DESTDIR)/${docdir}
+endif
AC_DEFINE(LIBDBUSPOLICY_TESTS_API, 1, [Define if tests are enabled])
fi
+
+AC_ARG_ENABLE([doxygen],
+ AS_HELP_STRING([--enable-doxygen], [enable doxygen documentation @<:@default=disabled@:>@]),
+ [], [enable_doxygen=no])
+AM_CONDITIONAL([ENABLE_DOXYGEN], [test x$enable_doxygen = xyes])
+AS_IF([test "x$enable_doxygen" = "xyes"], [
+ AC_CHECK_PROGS([DOXYGEN], [doxygen])
+ if test -z "$DOXYGEN"
+ then AC_MSG_ERROR([Doxygen not found!])
+ enable_doxygen=no
+ fi
+])
+
AC_CHECK_FUNCS([ \
__secure_getenv \
secure_getenv\
logging: ${enable_logging}
debug: ${enable_debug}
+ doxygen: ${enable_doxygen}
])
--- /dev/null
+PROJECT_NAME = "libdbuspolicy"
+OUTPUT_DIRECTORY = documentation
+GENERATE_LATEX = NO
+GENERATE_MAN = NO
+GENERATE_RTF = NO
+CASE_SENSE_NAMES = NO
+INPUT = src/dbuspolicy1/libdbuspolicy1.h
+JAVADOC_AUTOBRIEF = YES
+EXTRACT_PRIVATE = YES
+EXTRACT_STATIC = YES
+TYPEDEF_HIDES_STRUCT = YES
+INLINE_SOURCES = YES
+REFERENCED_BY_RELATION = YES
+REFERENCES_RELATION = YES
+SEARCHENGINE = NO
+COMPACT_LATEX = YES
+LATEX_HIDE_INDICES = YES
BuildRequires: boost-devel
BuildRequires: pkgconfig(cynara-client)
-
%package devel
Summary: Helper library for fine-grained userspace policy handling-development package
Requires: %{name} = %{version}
policy handling (with SMACK support). This package contains
development files.
+
+%if 0%{?enable_doxygen:1}
+%package doc
+Summary: Documentation for libdbuspolicy
+BuildRequires: doxygen
+
+%description doc
+Doxygen documentation for libdbuspolicy.
+%endif
+
%prep
%setup -q
cp %{SOURCE1001} .
%build
%reconfigure --libdir=%{_libdir} --prefix=/usr \
%if 0%{?test_version}
---enable-tests
+--enable-tests \
%endif
+%if 0%{?enable_doxygen:1}
+--enable-doxygen
+%endif
+
make
make check
%{_libdir}/libdbuspolicy1.so
%manifest %{name}.manifest
+%if 0%{?enable_doxygen:1}
+%files doc
+%defattr(-,root,root)
+%{_datadir}/doc/dbuspolicy/*
+%endif
%changelog
* limitations under the License.
*/
+/**
+ * \file libdbuspolicy1.h
+ */
#ifndef _LIBDBUSPOLICY1_H_
#define _LIBDBUSPOLICY1_H_