From: Kefu Chai Date: Tue, 17 Mar 2015 15:40:00 +0000 (+0800) Subject: doc: Switch doxygen integration back to breathe X-Git-Tag: v9.0.0~136^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=cd69ded7affcdd754e229f94989a62c46f0a117b;p=ceph.git doc: Switch doxygen integration back to breathe * asphyxiate needs more toolings, see https://github.com/ceph/asphyxiate/issues/1 * this commit basically reverts c96064 * use `autodoxygen` directive to doxygen referenced source files * do not call `doxygen` explicitly in `build-doc`, `autodoxygen` will take care of it. Fixes: #6115 Fixes: #6115 Signed-off-by: Kefu Chai --- diff --git a/admin/build-doc b/admin/build-doc index dfbd5e45f0f6..f3ebd3402e39 100755 --- a/admin/build-doc +++ b/admin/build-doc @@ -47,10 +47,6 @@ else fi fi -if [ ! -e build-doc/doxygen/xml ]; then - doxygen -fi - cat src/osd/PG.h src/osd/PG.cc | doc/scripts/gen_state_diagram.py > doc/dev/peering_graph.generated.dot cd build-doc diff --git a/admin/doc-requirements.txt b/admin/doc-requirements.txt index ce4654c66000..aba92c28bef9 100644 --- a/admin/doc-requirements.txt +++ b/admin/doc-requirements.txt @@ -1,3 +1,3 @@ Sphinx == 1.1.3 -e git+https://github.com/ceph/sphinx-ditaa.git#egg=sphinx-ditaa --e git+https://github.com/ceph/asphyxiate.git#egg=asphyxiate +-e git+https://github.com/michaeljones/breathe#egg=breathe diff --git a/doc/conf.py b/doc/conf.py index 98ce7d861b3a..99c66ed38493 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -28,7 +28,7 @@ extensions = [ 'sphinx.ext.graphviz', 'sphinx.ext.todo', 'sphinx_ditaa', - 'asphyxiate', + 'breathe', ] todo_include_todos = True @@ -69,14 +69,21 @@ def _get_manpages(): man_pages = list(_get_manpages()) -asphyxiate_doxygen_xml = 'doxygen' - top_level = os.path.dirname( os.path.dirname( os.path.abspath(__file__) ) ) +breathe_default_project = "Ceph" +# see $(top_srcdir)/Doxyfile + +breathe_build_directory = os.path.join(top_level, "build-doc") +breathe_projects = {"Ceph": os.path.join(top_level, breathe_build_directory)} +breathe_projects_source = { + "Ceph": (os.path.join(top_level, "src/include/rados"), + ["rados_types.h", "librados.h"]) +} pybind = os.path.join(top_level, 'src/pybind') if pybind not in sys.path: sys.path.insert(0, pybind) diff --git a/doc/rados/api/librados.rst b/doc/rados/api/librados.rst index 5c3742fc8064..483ef8e67764 100644 --- a/doc/rados/api/librados.rst +++ b/doc/rados/api/librados.rst @@ -183,5 +183,5 @@ Note that all the :c:type:`rados_completion_t` must be freed with :c:func:`rados API calls ========= - .. doxygenfile:: rados_types.h - .. doxygenfile:: librados.h + .. autodoxygenfile:: rados_types.h + .. autodoxygenfile:: librados.h