diff options
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 6b9fbfc..0cf3b20 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -12,6 +12,26 @@ set(Boost_USE_STATIC_RUNTIME OFF) add_definitions(-DBOOST_ALL_DYN_LINK) +find_package(Doxygen) +if (DOXYGEN_FOUND) + set(doxyfile_in ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in) + set(doxyfile ${PROJECT_BINARY_DIR}/Doxyfile) + set(doxy_html_index_file ${CMAKE_CURRENT_BINARY_DIR}/html/index.html) + + configure_file( + ${doxyfile_in} + ${doxyfile} @ONLY) + + add_custom_command( + OUTPUT ${doxy_html_index_file} + COMMAND ${DOXYGEN_EXECUTABLE} ${doxyfile} + MAIN_DEPENDENCY ${doxyfile} ${doxyfile_in} + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} + COMMENT "Generating documentation" VERBATIM) + + add_custom_target(doc DEPENDS ${doxy_html_index_file} ) +endif(DOXYGEN_FOUND) + add_subdirectory(ble) add_subdirectory(apps) add_subdirectory(test) |