chore: added CPM and doc cmake
[KDIS.git] / doc / CMakeLists.txt
blob74d07795916d3a60b2082c364b3edb6298093da2
1 find_package(Doxygen)
3 if(DOXYGEN_FOUND)
4   set(DOXYGEN_IN "${CMAKE_SOURCE_DIR}/Doxyfile.in")
5   set(DOXYGEN_OUT "${CMAKE_CURRENT_BINARY_DIR}/Doxyfile")
7   configure_file(${DOXYGEN_IN} ${DOXYGEN_OUT} @ONLY)
9   add_custom_target(
10     doc
11     COMMAND ${DOXYGEN_EXECUTABLE} ${DOXYGEN_OUT}
12     WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
13     COMMENT "Generating API documentation with Doxygen"
14     VERBATIM)
15 else()
16   message(STATUS "Doxygen need to be installed to generate the documentation")
17 endif()