blob: ae25c920876d3fa5db7fba6e65119183db8d2e00 [file] [log] [blame]
bin.chen1a426d32021-10-13 10:52:36 +08001# set input and output files
2set(DOXYGEN_IN ${SDK_BASE}/doc/Doxyfile)
3set(DOXYGEN_OUT ${PROJECT_BINARY_DIR}/Doxyfile)
4
5# check if Doxygen is installed
6find_package(Doxygen)
7if (DOXYGEN_FOUND)
8
9 # request to configure the file
10 configure_file(${DOXYGEN_IN} ${DOXYGEN_OUT} @ONLY)
11 message("Doxygen build started")
12
13 # note the option ALL which allows to build the docs together with the application
14 add_custom_target( doc_doxygen ALL
15 COMMAND ${DOXYGEN_EXECUTABLE} ${DOXYGEN_OUT}
16 WORKING_DIRECTORY ${PROJECT_BINARY_DIR}
17 COMMENT "Generating API documentation with Doxygen"
18 VERBATIM )
19else (DOXYGEN_FOUND)
20 message("Doxygen need to be installed to generate the doxygen documentation")
21endif (DOXYGEN_FOUND)