Skip to content
Snippets Groups Projects
Verified Commit d6d065bc authored by Daniel Hornung's avatar Daniel Hornung
Browse files

ENH: Explicit dependency on clang-tidy-16, and checks.

See !92 for the relevant issue.
parent d18b8a04
Branches
No related tags found
2 merge requests!61Release 0.3.0,!57Fix deprecations + updates
Pipeline #55662 canceled
...@@ -4,7 +4,7 @@ RUN apt-get update ...@@ -4,7 +4,7 @@ RUN apt-get update
RUN apt-get install -y cmake RUN apt-get install -y cmake
RUN apt-get install -y lcov RUN apt-get install -y lcov
RUN apt-get install -y doxygen graphviz RUN apt-get install -y doxygen graphviz
RUN apt-get install -y clang-format-16 clang-tidy RUN apt-get install -y clang-format-16 clang-tidy-16
RUN apt-get install -y python3-pip python3-venv RUN apt-get install -y python3-pip python3-venv
RUN apt-get install -y git RUN apt-get install -y git
RUN apt-get install -y curl zip unzip tar RUN apt-get install -y curl zip unzip tar
......
...@@ -320,7 +320,7 @@ if(_LINTING) ...@@ -320,7 +320,7 @@ if(_LINTING)
) )
endif() endif()
find_program(clang_tidy NAMES clang-tidy clang-tidy-11) find_program(clang_tidy NAMES clang-tidy clang-tidy-16)
if(NOT clang_tidy) if(NOT clang_tidy)
message(WARNING "clang-tidy: Not found") message(WARNING "clang-tidy: Not found")
else() else()
...@@ -439,7 +439,7 @@ install(FILES ${PROJECT_SOURCE_DIR}/linkaheadConfigVersion.cmake ...@@ -439,7 +439,7 @@ install(FILES ${PROJECT_SOURCE_DIR}/linkaheadConfigVersion.cmake
####################################################### #######################################################
option(AUTOFORMATTING "call clang-format at configure time" ON) option(AUTOFORMATTING "call clang-format at configure time" ON)
if(AUTOFORMATTING AND NOT SKIP_LINTING) if(AUTOFORMATTING AND NOT SKIP_LINTING)
find_program(clang_format NAMES clang-format-11 clang-format) find_program(clang_format NAMES clang-format-16 clang-format)
file(GLOB format_test_sources test/*.cpp test/*.h test/*.h.in) file(GLOB format_test_sources test/*.cpp test/*.h test/*.h.in)
execute_process(COMMAND ${clang_format} -i --verbose ${liblinkahead_INCL} execute_process(COMMAND ${clang_format} -i --verbose ${liblinkahead_INCL}
${liblinkahead_SRC} ${liblinkahead_TEST_SRC} ${liblinkahead_SRC} ${liblinkahead_TEST_SRC}
......
...@@ -59,7 +59,6 @@ help: ...@@ -59,7 +59,6 @@ help:
@echo " test-release - Install dependencies, build the project in Release mode, and run the tests." @echo " test-release - Install dependencies, build the project in Release mode, and run the tests."
@echo " clean - Remove build directory." @echo " clean - Remove build directory."
style: style:
$(CLANG_FORMAT) -i --verbose \ $(CLANG_FORMAT) -i --verbose \
$$(find test/ src/ include/ -type f -iname "*.cpp" -o -iname "*.h" -o -iname "*.h.in") $$(find test/ src/ include/ -type f -iname "*.cpp" -o -iname "*.h" -o -iname "*.h.in")
...@@ -105,6 +104,9 @@ conan-build: ...@@ -105,6 +104,9 @@ conan-build:
.PHONY: conan-build .PHONY: conan-build
conan-build-debug: conan-build-debug:
@command -v lcov || (echo "Could not find 'lcov', exiting."; exit 1)
@command -v clang-tidy || command -v clang-tidy-16 || \
(echo "Could not find 'clang-tidy'(-16), exiting."; exit 1)
conan build . -s $(CONAN_SETTINGS) -s build_type=Debug conan build . -s $(CONAN_SETTINGS) -s build_type=Debug
.PHONY: conan-build-debug .PHONY: conan-build-debug
......
...@@ -32,7 +32,7 @@ python packages from the `doc/requirements.txt` file ...@@ -32,7 +32,7 @@ python packages from the `doc/requirements.txt` file
## Build and run tests ## ## Build and run tests ##
``` ```
>=clang-tidy-11 clang-tidy-16
>=gtest-1.10.0 >=gtest-1.10.0
``` ```
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment