mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 03:33:20 +01:00
0949b71567
The option LLVM_ENABLE_SPHINX option enables the "docs-llvm-html", "docs-llvm-man" targets but does not build them by default. The following CMake options have been added that control what targets are made available SPHINX_OUTPUT_HTML SPHINX_OUTPUT_MAN If LLVM_BUILD_DOCS is enabled then the enabled docs-llvm-* targets will be built by default and if ``make install`` is run then docs-llvm-html and docs-llvm-man will be installed (tested on Linux only). The add_sphinx_target function is in its own file so it can be included by other projects that use Sphinx for their documentation. Patch by Daniel Liew <daniel.liew@imperial.ac.uk>! llvm-svn: 206655
26 lines
846 B
CMake
26 lines
846 B
CMake
# CMake find_package() Module for Sphinx documentation generator
|
|
# http://sphinx-doc.org/
|
|
#
|
|
# Example usage:
|
|
#
|
|
# find_package(Sphinx)
|
|
#
|
|
# If successful the following variables will be defined
|
|
# SPHINX_FOUND
|
|
# SPHINX_EXECUTABLE
|
|
|
|
find_program(SPHINX_EXECUTABLE
|
|
NAMES sphinx-build sphinx-build2
|
|
DOC "Path to sphinx-build executable")
|
|
|
|
# Handle REQUIRED and QUIET arguments
|
|
# this will also set SPHINX_FOUND to true if SPHINX_EXECUTABLE exists
|
|
include(FindPackageHandleStandardArgs)
|
|
find_package_handle_standard_args(Sphinx
|
|
"Failed to locate sphinx-build executable"
|
|
SPHINX_EXECUTABLE)
|
|
|
|
# Provide options for controlling different types of output
|
|
option(SPHINX_OUTPUT_HTML "Output standalone HTML files" ON)
|
|
option(SPHINX_OUTPUT_MAN "Output man pages" ON)
|