Sun, 26 Sep 2021 13:41:52 +0200
change detection of Doxygen
CMakeLists.txt | file | annotate | diff | comparison | revisions |
--- a/CMakeLists.txt Sun Sep 26 13:06:48 2021 +0200 +++ b/CMakeLists.txt Sun Sep 26 13:41:52 2021 +0200 @@ -16,14 +16,16 @@ add_subdirectory(docs/src) # API Documentation +message(CHECK_START "Seaching for Doxygen") find_package(Doxygen) -option(BUILD_DOCUMENTATION "Create API documentation." ${DOXYGEN_FOUND}) +if(DOXYGEN_FOUND) + message(CHECK_PASS "found.") +else() + message(CHECK_FAIL "not found - documentation will not be generated.") +endif() +option(BUILD_API_DOC "Create API documentation." ON) -if(BUILD_DOCUMENTATION) - if(NOT DOXYGEN_FOUND) - message(FATAL_ERROR "Doxygen is needed to build the documentation.") - endif() - +if(BUILD_API_DOC AND DOXYGEN_FOUND) set(DOXY_INPUT ${CMAKE_SOURCE_DIR}/src) set(DOXY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/docs) set(DOXY_PROJECT_LOGO ${CMAKE_SOURCE_DIR}/uaplogo.png)