blob: 70bf9985cdf34a5acdcd767fcbf4f095e1da1a00 [file] [log] [blame]
Austin Schuh70cc9552019-01-21 19:46:48 -08001find_package(Sphinx REQUIRED)
2
3# HTML output directory
4set(SPHINX_HTML_DIR "${Ceres_BINARY_DIR}/docs/html")
5
6# Install documentation
7install(DIRECTORY ${SPHINX_HTML_DIR}
8 DESTINATION "${CERES_DOCS_INSTALL_DIR}"
9 COMPONENT Doc
10 PATTERN "${SPHINX_HTML_DIR}/*")
11
12# Building using 'make_docs.py' python script
13add_custom_target(ceres_docs ALL
14 python
15 "${Ceres_SOURCE_DIR}/scripts/make_docs.py"
16 "${Ceres_SOURCE_DIR}"
17 "${Ceres_BINARY_DIR}/docs"
18 "${SPHINX_EXECUTABLE}"
19 COMMENT "Building HTML documentation with Sphinx")