diff options
author | Gereon Kremer <gkremer@stanford.edu> | 2021-05-04 18:33:59 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-04 18:33:59 +0200 |
commit | f41ae5481e9eb68aeeb87d57fca89e63501c6213 (patch) | |
tree | 5d012529e08b89f7a4ef4deb57c542ae111059e8 /docs/CMakeLists.txt | |
parent | 441c53b1a68cc16a345eb0dc8d9956c1301ed509 (diff) |
Improve generation of python API documentation (#6482)
This PR makes generating the python part of our API documentation more reliable. If python bindings are enabled, it makes the docs target depend on pycvc5 and renders a warning into the documentation if python bindings are disabled.
To make the dependency on pycvc5 work properly, it changes the python bindings build so that the library is directly put in the right place and avoid the manual rename, so that the pycvc5 target actually points to the correct file.
Unfortunately, this means we need to build libcvc5 when building docs with python bindings enabled.
Diffstat (limited to 'docs/CMakeLists.txt')
-rw-r--r-- | docs/CMakeLists.txt | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/docs/CMakeLists.txt b/docs/CMakeLists.txt index b08668afa..4c5d9aa6c 100644 --- a/docs/CMakeLists.txt +++ b/docs/CMakeLists.txt @@ -18,6 +18,7 @@ check_python_module(sphinxcontrib.bibtex sphinxcontrib-bibtex) check_python_module(sphinx_tabs.tabs sphinx-tabs) add_subdirectory(cpp) +add_subdirectory(python) set(SPHINX_INPUT_DIR ${CMAKE_CURRENT_SOURCE_DIR}) set(SPHINX_OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR}/sphinx) @@ -25,7 +26,7 @@ set(SPHINX_OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR}/sphinx) configure_file(conf.py.in ${CMAKE_CURRENT_BINARY_DIR}/conf.py) add_custom_target(docs ALL - DEPENDS docs-cpp + DEPENDS docs-cpp docs-python COMMAND ${SPHINX_EXECUTABLE} -b html -c ${CMAKE_CURRENT_BINARY_DIR} |