Commit ee359ebd authored by Dominik Charousset's avatar Dominik Charousset

Add new meta-target doc

parent 009b5086
...@@ -2,6 +2,8 @@ cmake_minimum_required(VERSION 3.10) ...@@ -2,6 +2,8 @@ cmake_minimum_required(VERSION 3.10)
project(doc NONE) project(doc NONE)
add_custom_target(doc)
# -- list all .tex source files ------------------------------------------------ # -- list all .tex source files ------------------------------------------------
set(sources set(sources
...@@ -70,6 +72,7 @@ else() ...@@ -70,6 +72,7 @@ else()
WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
COMMENT "Generating API documentation with Doxygen" COMMENT "Generating API documentation with Doxygen"
VERBATIM) VERBATIM)
add_dependencies(doc doxygen)
endif() endif()
# -- Pandoc utility macro ------------------------------------------------------ # -- Pandoc utility macro ------------------------------------------------------
...@@ -106,6 +109,7 @@ else() ...@@ -106,6 +109,7 @@ else()
IMAGE_DIRS "pdf" IMAGE_DIRS "pdf"
FORCE_PDF FORCE_PDF
TARGET_NAME manual) TARGET_NAME manual)
add_dependencies(doc manual)
find_program(PANDOC_EXECUTABLE pandoc) find_program(PANDOC_EXECUTABLE pandoc)
if(NOT EXISTS ${PANDOC_EXECUTABLE}) if(NOT EXISTS ${PANDOC_EXECUTABLE})
message(STATUS "Pandoc not found, skip generating reFormattedText version of the manual.") message(STATUS "Pandoc not found, skip generating reFormattedText version of the manual.")
...@@ -120,6 +124,7 @@ else() ...@@ -120,6 +124,7 @@ else()
else() else()
message(STATUS "Add optional target: rst.") message(STATUS "Add optional target: rst.")
add_custom_target(rst) add_custom_target(rst)
add_dependencies(doc rst)
foreach(texfile ${sources}) foreach(texfile ${sources})
generate_rst(${texfile}) generate_rst(${texfile})
endforeach() endforeach()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment