diff --git a/owlps-positioner/CMakeLists.txt b/owlps-positioner/CMakeLists.txt index f6398d5..bf5ba20 100644 --- a/owlps-positioner/CMakeLists.txt +++ b/owlps-positioner/CMakeLists.txt @@ -73,3 +73,29 @@ add_executable(owlps-positionerd.semistatic EXCLUDE_FROM_ALL target_link_libraries(owlps-positionerd.semistatic libowlps.a ${EXTRA_LIBS}) + + +### Extra targets ### + +# Indentation +set(INDENTER astyle --style=gnu --indent=spaces=2 --formatted --recursive) +add_custom_target(indent_positioner + ${INDENTER} src/*.cc src/*.hh + WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}" + COMMENT "Reindenting source files" + VERBATIM) + +# cppcheck +set(CODE_CHECKER cppcheck --quiet --enable=all) +add_custom_target(check_positioner + ${CODE_CHECKER} src/*.hh src/*.cc + WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}" + COMMENT "Checking source code") + +# Documentation +set(DOXYGEN OWLPS_VERSION=${OWLPS_VERSION} doxygen >/dev/null) +set(DOXYFILE Doxyfile) +add_custom_target(doc_positioner + ${DOXYGEN} ${DOXYFILE} + WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}" + COMMENT "Generating Doxygen documentation for OwlPS Positioner")