[PATCH] D23757: cmake: Support overriding Sphinx HTML doc install directory
Michał Górny via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 23 04:18:24 PDT 2016
This revision was automatically updated to reflect the committed changes.
Closed by commit rL282240: cmake: Support overriding Sphinx HTML doc install directory (authored by mgorny).
Changed prior to commit:
https://reviews.llvm.org/D23757?vs=72060&id=72249#toc
Repository:
rL LLVM
https://reviews.llvm.org/D23757
Files:
llvm/trunk/cmake/modules/AddSphinxTarget.cmake
llvm/trunk/docs/CMake.rst
Index: llvm/trunk/docs/CMake.rst
===================================================================
--- llvm/trunk/docs/CMake.rst
+++ llvm/trunk/docs/CMake.rst
@@ -456,6 +456,11 @@
If enabled then sphinx documentation warnings will be treated as
errors. Defaults to ON.
+**LLVM_INSTALL_SPHINX_HTML_DIR**:STRING
+ The path to install Sphinx-generated HTML documentation to. This path can
+ either be absolute or relative to the CMAKE_INSTALL_PREFIX. Defaults to
+ `share/doc/llvm/html`.
+
**LLVM_CREATE_XCODE_TOOLCHAIN**:BOOL
OS X Only: If enabled CMake will generate a target named
'install-xcode-toolchain'. This target will create a directory at
Index: llvm/trunk/cmake/modules/AddSphinxTarget.cmake
===================================================================
--- llvm/trunk/cmake/modules/AddSphinxTarget.cmake
+++ llvm/trunk/cmake/modules/AddSphinxTarget.cmake
@@ -53,8 +53,15 @@
DESTINATION share/man/man1)
elseif (builder STREQUAL html)
- install(DIRECTORY "${SPHINX_BUILD_DIR}"
- DESTINATION "share/doc/${project}")
+ string(TOUPPER "${project}" project_upper)
+ set(${project_upper}_INSTALL_SPHINX_HTML_DIR "share/doc/${project}/html"
+ CACHE STRING "HTML documentation install directory for ${project}")
+
+ # '/.' indicates: copy the contents of the directory directly into
+ # the specified destination, without recreating the last component
+ # of ${SPHINX_BUILD_DIR} implicitly.
+ install(DIRECTORY "${SPHINX_BUILD_DIR}/."
+ DESTINATION "${${project_upper}_INSTALL_SPHINX_HTML_DIR}")
else()
message(WARNING Installation of ${builder} not supported)
endif()
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D23757.72249.patch
Type: text/x-patch
Size: 1735 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160923/2bb59ea6/attachment.bin>
More information about the llvm-commits
mailing list