summaryrefslogtreecommitdiffstats
path: root/Utilities/Sphinx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-05-01 17:14:25 (GMT)
committerBrad King <brad.king@kitware.com>2017-05-01 17:18:25 (GMT)
commitc273906f48f6e0a84917351288b68a1ec0da64cd (patch)
treed63e06dbf308e199694ce23c06d4ce0fe9a5d1c7 /Utilities/Sphinx
parente80e8eb609cc7dd8c4dca46b9c2819afd2293229 (diff)
downloadCMake-c273906f48f6e0a84917351288b68a1ec0da64cd.zip
CMake-c273906f48f6e0a84917351288b68a1ec0da64cd.tar.gz
CMake-c273906f48f6e0a84917351288b68a1ec0da64cd.tar.bz2
Utilities/Sphinx: Build documentation independently by default
Previously we made the `documentation` target depend on the executable targets. There is no real reason to do this other than serializing the documentation build output in terminals. Move this dependency behind an undocumented option so that it is not on by default.
Diffstat (limited to 'Utilities/Sphinx')
-rw-r--r--Utilities/Sphinx/CMakeLists.txt26
1 files changed, 14 insertions, 12 deletions
diff --git a/Utilities/Sphinx/CMakeLists.txt b/Utilities/Sphinx/CMakeLists.txt
index edb9469..a29380c 100644
--- a/Utilities/Sphinx/CMakeLists.txt
+++ b/Utilities/Sphinx/CMakeLists.txt
@@ -128,18 +128,20 @@ endforeach()
add_custom_target(documentation ALL DEPENDS ${doc_format_outputs})
-foreach(t
- cmake
- ccmake
- cmake-gui
- cpack
- ctest
- )
- if(TARGET ${t})
- # Build documentation after main executables.
- add_dependencies(documentation ${t})
- endif()
-endforeach()
+if(CMake_SPHINX_DEPEND_ON_EXECUTABLES)
+ foreach(t
+ cmake
+ ccmake
+ cmake-gui
+ cpack
+ ctest
+ )
+ if(TARGET ${t})
+ # Build documentation after main executables.
+ add_dependencies(documentation ${t})
+ endif()
+ endforeach()
+endif()
if(SPHINX_MAN)
file(GLOB man_rst RELATIVE ${CMake_SOURCE_DIR}/Help/manual