From 9537bbf0eb8dbf7ca55c9baafd6a26b44af83267 Mon Sep 17 00:00:00 2001 From: Kefu Chai Date: Fri, 28 Aug 2020 18:20:13 +0800 Subject: [PATCH] doc/conf.py: define CEPH_RADOS_API for breathe otherwise we could have following errors: Invalid C declaration: Expected identifier in nested name, got keyword: int [error at 18] CEPH_RADOS_API int rados_aio_append (rados_ioctx_t io, const char *oid, rados_completion_t completion, const char *buf, size_t len) ------------------^ Signed-off-by: Kefu Chai (cherry picked from commit cf357e17ab5cbd9af4f67c51117b5f368cb9913f) --- doc/conf.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/doc/conf.py b/doc/conf.py index 7c84eaf84b15a..c5638baa4f11d 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -99,6 +99,11 @@ breathe_projects_source = { ["rados_types.h", "librados.h"]) } breathe_domain_by_extension = {'py': 'py', 'c': 'c', 'h': 'c', 'cc': 'cxx', 'hpp': 'cxx'} +breathe_doxygen_config_options = { + 'EXPAND_ONLY_PREDEF': 'YES', + 'MACRO_EXPANSION': 'YES', + 'PREDEFINED': 'CEPH_RADOS_API= ' +} # the docs are rendered with github links pointing to master. the javascript # snippet in _static/ceph.js rewrites the edit links when a page is loaded, to -- 2.39.5