r203801 - CMake: allow generation of a Qt Compressed Help file for Clang source
Dmitri Gribenko
gribozavr at gmail.com
Thu Mar 13 07:17:01 PDT 2014
Author: gribozavr
Date: Thu Mar 13 09:17:01 2014
New Revision: 203801
URL: http://llvm.org/viewvc/llvm-project?rev=203801&view=rev
Log:
CMake: allow generation of a Qt Compressed Help file for Clang source
r203272 enables generation of a Qt Compressed Help file for the LLVM source
code.
As a consequence, this change brings the same capabilities to Clang while
reusing these two variables:
LLVM_ENABLE_DOXYGEN_QT_HELP
LLVM_DOXYGEN_QHELPGENERATOR_PATH
and adding
CLANG_DOXYGEN_QCH_FILENAME="org.llvm.clang.qch"
CLANG_DOXYGEN_QHP_NAMESPACE="org.llvm.clang"
CLANG_DOXYGEN_QHP_CUST_FILTER_NAME="Clang ${CLANG_VERSION}"
CLANG_DOXYGEN_QHP_CUST_FILTER_ATTRS="Clang,${CLANG_VERSION}"
Patch by Konrad Kleine.
Modified:
cfe/trunk/docs/CMakeLists.txt
cfe/trunk/docs/doxygen.cfg.in
Modified: cfe/trunk/docs/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/docs/CMakeLists.txt?rev=203801&r1=203800&r2=203801&view=diff
==============================================================================
--- cfe/trunk/docs/CMakeLists.txt (original)
+++ cfe/trunk/docs/CMakeLists.txt Thu Mar 13 09:17:01 2014
@@ -22,6 +22,31 @@ if (LLVM_ENABLE_DOXYGEN)
set(extra_search_mappings "")
endif()
+ # If asked, configure doxygen for the creation of a Qt Compressed Help file.
+ if (LLVM_ENABLE_DOXYGEN_QT_HELP)
+ set(CLANG_DOXYGEN_QCH_FILENAME "org.llvm.clang.qch" CACHE STRING
+ "Filename of the Qt Compressed help file")
+ set(CLANG_DOXYGEN_QHP_NAMESPACE "org.llvm.clang" CACHE STRING
+ "Namespace under which the intermediate Qt Help Project file lives")
+ set(CLANG_DOXYGEN_QHP_CUST_FILTER_NAME "Clang ${CLANG_VERSION}" CACHE STRING
+ "See http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom-filters")
+ set(CLANG_DOXYGEN_QHP_CUST_FILTER_ATTRS "Clang,${CLANG_VERSION}" CACHE STRING
+ "See http://qt-project.org/doc/qt-4.8/qthelpproject.html#filter-attributes")
+ set(clang_doxygen_generate_qhp "YES")
+ set(clang_doxygen_qch_filename "${CLANG_DOXYGEN_QCH_FILENAME}")
+ set(clang_doxygen_qhp_namespace "${CLANG_DOXYGEN_QHP_NAMESPACE}")
+ set(clang_doxygen_qhelpgenerator_path "${LLVM_DOXYGEN_QHELPGENERATOR_PATH}")
+ set(clang_doxygen_qhp_cust_filter_name "${CLANG_DOXYGEN_QHP_CUST_FILTER_NAME}")
+ set(clang_doxygen_qhp_cust_filter_attrs "${CLANG_DOXYGEN_QHP_CUST_FILTER_ATTRS}")
+ else()
+ set(clang_doxygen_generate_qhp "NO")
+ set(clang_doxygen_qch_filename "")
+ set(clang_doxygen_qhp_namespace "")
+ set(clang_doxygen_qhelpgenerator_path "")
+ set(clang_doxygen_qhp_cust_filter_name "")
+ set(clang_doxygen_qhp_cust_filter_attrs "")
+ endif()
+
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/doxygen.cfg.in
${CMAKE_CURRENT_BINARY_DIR}/doxygen.cfg @ONLY)
@@ -33,6 +58,12 @@ if (LLVM_ENABLE_DOXYGEN)
set(enable_server_based_search)
set(enable_external_search)
set(extra_search_mappings)
+ set(clang_doxygen_generate_qhp)
+ set(clang_doxygen_qch_filename)
+ set(clang_doxygen_qhp_namespace)
+ set(clang_doxygen_qhelpgenerator_path)
+ set(clang_doxygen_qhp_cust_filter_name)
+ set(clang_doxygen_qhp_cust_filter_attrs)
add_custom_target(doxygen-clang
COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/doxygen.cfg
Modified: cfe/trunk/docs/doxygen.cfg.in
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/docs/doxygen.cfg.in?rev=203801&r1=203800&r2=203801&view=diff
==============================================================================
--- cfe/trunk/docs/doxygen.cfg.in (original)
+++ cfe/trunk/docs/doxygen.cfg.in Thu Mar 13 09:17:01 2014
@@ -697,6 +697,59 @@ BINARY_TOC = NO
TOC_EXPAND = NO
+# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and
+# QHP_VIRTUAL_FOLDER are set, an additional index file will be generated
+# that can be used as input for Qt's qhelpgenerator to generate a
+# Qt Compressed Help (.qch) of the generated HTML documentation.
+
+GENERATE_QHP = @clang_doxygen_generate_qhp@
+
+# If the QHG_LOCATION tag is specified, the QCH_FILE tag can
+# be used to specify the file name of the resulting .qch file.
+# The path specified is relative to the HTML output folder.
+
+QCH_FILE = @clang_doxygen_qch_filename@
+
+# The QHP_NAMESPACE tag specifies the namespace to use when generating
+# Qt Help Project output. For more information please see
+# http://qt-project.org/doc/qt-4.8/qthelpproject.html#namespace
+
+QHP_NAMESPACE = @clang_doxygen_qhp_namespace@
+
+# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating
+# Qt Help Project output. For more information please see
+# http://qt-project.org/doc/qt-4.8/qthelpproject.html#virtual-folders
+
+QHP_VIRTUAL_FOLDER = doc
+
+# If QHP_CUST_FILTER_NAME is set, it specifies the name of a custom filter to
+# add. For more information please see
+# http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom-filters
+
+QHP_CUST_FILTER_NAME = @clang_doxygen_qhp_cust_filter_name@
+
+# The QHP_CUST_FILT_ATTRS tag specifies the list of the attributes of the
+# custom filter to add. For more information please see
+# <a href="http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom-filters">
+# Qt Help Project / Custom Filters</a>.
+
+QHP_CUST_FILTER_ATTRS = @clang_doxygen_qhp_cust_filter_attrs@
+
+# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this
+# project's
+# filter section matches.
+# <a href="http://qt-project.org/doc/qt-4.8/qthelpproject.html#filter-attributes">
+# Qt Help Project / Filter Attributes</a>.
+
+QHP_SECT_FILTER_ATTRS =
+
+# If the GENERATE_QHP tag is set to YES, the QHG_LOCATION tag can
+# be used to specify the location of Qt's qhelpgenerator.
+# If non-empty doxygen will try to run qhelpgenerator on the generated
+# .qhp file.
+
+QHG_LOCATION = @clang_doxygen_qhelpgenerator_path@
+
# The DISABLE_INDEX tag can be used to turn on/off the condensed index at
# top of each HTML page. The value NO (the default) enables the index and
# the value YES disables it.
More information about the cfe-commits
mailing list