mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-22 10:42:39 +01:00
[doxygen] Use correct variable names for external variable configuration and make EXTRA_SEARCH_MAPPINGS a "dumb" variable.
I do not think the massaging that I was doing for EXTRA_SEARCH_MAPPINGS was truly necessary. llvm-svn: 189522
This commit is contained in:
parent
a44903bdb6
commit
1659d8245b
@ -473,8 +473,12 @@ if (LLVM_ENABLE_DOXYGEN)
|
|||||||
if (LLVM_BUILD_DOCS)
|
if (LLVM_BUILD_DOCS)
|
||||||
add_custom_target(doxygen ALL)
|
add_custom_target(doxygen ALL)
|
||||||
endif()
|
endif()
|
||||||
option(DOXYGEN_EXTERNAL_SEARCH "Enable doxygen external search." OFF)
|
|
||||||
set(DOXYGEN_SEARCH_MAPPINGS "" CACHE STRING "Doxygen Search Mappings")
|
option(LLVM_DOXYGEN_EXTERNAL_SEARCH "Enable doxygen external search." OFF)
|
||||||
|
if (LLVM_DOXYGEN_EXTERNAL_SEARCH)
|
||||||
|
set(LLVM_DOXYGEN_SEARCHENGINE_URL "" CACHE STRING "URL to use for external searhc.")
|
||||||
|
set(LLVM_DOXYGEN_SEARCH_MAPPINGS "" CACHE STRING "Doxygen Search Mappings")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
else()
|
else()
|
||||||
message(STATUS "Doxygen disabled.")
|
message(STATUS "Doxygen disabled.")
|
||||||
|
@ -8,36 +8,31 @@ if (LLVM_ENABLE_DOXYGEN)
|
|||||||
set(DOT ${LLVM_PATH_DOT})
|
set(DOT ${LLVM_PATH_DOT})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (DOXYGEN_EXTERNAL_SEARCH)
|
if (LLVM_DOXYGEN_EXTERNAL_SEARCH)
|
||||||
set(SEARCHENGINE "YES")
|
set(enable_searchengine "YES")
|
||||||
set(SERVER_BASED_SEARCH "YES")
|
set(searchengine_url "${LLVM_DOXYGEN_SEARCHENGINE_URL}")
|
||||||
set(EXTERNAL_SEARCH "YES")
|
set(enable_server_based_search "YES")
|
||||||
|
set(enable_external_search "YES")
|
||||||
set(EXTRA_SEARCH_MAPPINGS "")
|
set(extra_search_mappings "${LLVM_DOXYGEN_SEARCH_MAPPINGS}")
|
||||||
foreach(NameAndValue ${DOXYGEN_SEARCH_MAPPINGS})
|
|
||||||
# Strip leading spaces
|
|
||||||
string(REGEX REPLACE "^[ ]+" "" NameAndValue ${NameAndValue})
|
|
||||||
# Find variable name
|
|
||||||
string(REGEX MATCH "^[^=]+" Name ${NameAndValue})
|
|
||||||
# Find the value
|
|
||||||
string(REPLACE "${Name}=" "" Value ${NameAndValue})
|
|
||||||
# Set the variable
|
|
||||||
if (NOT ${Name} EQUALS llvm)
|
|
||||||
set(EXTRA_SEARCH_MAPPINGS "${EXTRA_SEARCH_MAPPINGS} ${LLVM_BINARY_DIR}/${NameAndValue}")
|
|
||||||
endif()
|
|
||||||
endforeach()
|
|
||||||
else()
|
else()
|
||||||
set(SEARCHENGINE "NO")
|
set(enable_searchengine "NO")
|
||||||
set(SERVER_BASED_SEARCH "NO")
|
set(searchengine_url "")
|
||||||
set(EXTERNAL_SEARCH "NO")
|
set(enable_server_based_search "NO")
|
||||||
set(EXTRA_SEARCH_MAPPINGS "")
|
set(enable_external_search "NO")
|
||||||
|
set(extra_search_mappings "")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/doxygen.cfg.in
|
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/doxygen.cfg.in
|
||||||
${CMAKE_CURRENT_BINARY_DIR}/doxygen.cfg @ONLY)
|
${CMAKE_CURRENT_BINARY_DIR}/doxygen.cfg @ONLY)
|
||||||
|
|
||||||
set(abs_top_srcdir)
|
set(abs_top_srcdir)
|
||||||
set(abs_top_builddir)
|
set(abs_top_builddir)
|
||||||
set(DOT)
|
set(DOT)
|
||||||
|
set(enable_searchengine)
|
||||||
|
set(searchengine_url)
|
||||||
|
set(enable_server_based_search)
|
||||||
|
set(enable_external_search)
|
||||||
|
set(extra_search_mappings)
|
||||||
|
|
||||||
add_custom_target(doxygen-llvm
|
add_custom_target(doxygen-llvm
|
||||||
COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/doxygen.cfg
|
COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/doxygen.cfg
|
||||||
|
@ -21,9 +21,10 @@ $(PROJ_OBJ_DIR)/doxygen.cfg: doxygen.cfg.in
|
|||||||
-e 's/@PACKAGE_VERSION@/mainline/' \
|
-e 's/@PACKAGE_VERSION@/mainline/' \
|
||||||
-e 's/@abs_top_builddir@/../g' \
|
-e 's/@abs_top_builddir@/../g' \
|
||||||
-e 's/@enable_searchengine@/NO/g' \
|
-e 's/@enable_searchengine@/NO/g' \
|
||||||
-e 's/@enable_server_based_search@/NO/g' \
|
-e 's/@searchengine_url@//g' \
|
||||||
|
-e 's/@enable_server_based_search@/NO/g' \
|
||||||
-e 's/@enable_external_search@/NO/g' \
|
-e 's/@enable_external_search@/NO/g' \
|
||||||
-e 's/@extra_search_mappings@/NO/g' > $@
|
-e 's/@extra_search_mappings@//g' > $@
|
||||||
endif
|
endif
|
||||||
|
|
||||||
include $(LEVEL)/Makefile.common
|
include $(LEVEL)/Makefile.common
|
||||||
|
@ -1081,6 +1081,8 @@ SEARCHENGINE = @enable_searchengine@
|
|||||||
|
|
||||||
SERVER_BASED_SEARCH = @enable_server_based_search@
|
SERVER_BASED_SEARCH = @enable_server_based_search@
|
||||||
|
|
||||||
|
SEARCHENGINE_URL = @searchengine_url@
|
||||||
|
|
||||||
EXTERNAL_SEARCH = @enable_external_search@
|
EXTERNAL_SEARCH = @enable_external_search@
|
||||||
|
|
||||||
EXTERNAL_SEARCH_ID = llvm
|
EXTERNAL_SEARCH_ID = llvm
|
||||||
|
Loading…
Reference in New Issue
Block a user