summaryrefslogtreecommitdiff
path: root/Utilities/Sphinx/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'Utilities/Sphinx/CMakeLists.txt')
-rw-r--r--Utilities/Sphinx/CMakeLists.txt14
1 files changed, 13 insertions, 1 deletions
diff --git a/Utilities/Sphinx/CMakeLists.txt b/Utilities/Sphinx/CMakeLists.txt
index 23dc6ae1e4..5e3e04bfd2 100644
--- a/Utilities/Sphinx/CMakeLists.txt
+++ b/Utilities/Sphinx/CMakeLists.txt
@@ -24,6 +24,7 @@ project(CMakeHelp NONE)
option(SPHINX_MAN "Build man pages with Sphinx" OFF)
option(SPHINX_HTML "Build html help with Sphinx" OFF)
+option(SPHINX_SINGLEHTML "Build html single page help with Sphinx" OFF)
option(SPHINX_TEXT "Build text help with Sphinx (not installed)" OFF)
find_program(SPHINX_EXECUTABLE
NAMES sphinx-build
@@ -32,7 +33,7 @@ find_program(SPHINX_EXECUTABLE
mark_as_advanced(SPHINX_TEXT)
-if(NOT SPHINX_MAN AND NOT SPHINX_HTML AND NOT SPHINX_TEXT)
+if(NOT SPHINX_MAN AND NOT SPHINX_HTML AND NOT SPHINX_SINGLEHTML AND NOT SPHINX_TEXT)
return()
elseif(NOT SPHINX_EXECUTABLE)
message(FATAL_ERROR "SPHINX_EXECUTABLE (sphinx-build) is not found!")
@@ -60,6 +61,9 @@ endif()
if(SPHINX_MAN)
list(APPEND doc_formats man)
endif()
+if(SPHINX_SINGLEHTML)
+ list(APPEND doc_formats singlehtml)
+endif()
if(SPHINX_TEXT)
list(APPEND doc_formats text)
endif()
@@ -122,3 +126,11 @@ if(SPHINX_HTML)
PATTERN objects.inv EXCLUDE
)
endif()
+
+if(SPHINX_SINGLEHTML)
+ install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/singlehtml
+ DESTINATION ${CMAKE_DOC_DIR}
+ PATTERN .buildinfo EXCLUDE
+ PATTERN objects.inv EXCLUDE
+ )
+endif()