You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
writer_tests used in add_dependencies does only exist if tests are enabled. Add an additional AND BUILD_TESTING:
if(CLANG_TIDY AND PROTOBUF_FOUND AND BUILD_TESTING)
message(STATUS "Looking for clang-tidy - found ${CLANG_TIDY}")
add_custom_target(clang-tidy
${CLANG_TIDY}
-p ${CMAKE_BINARY_DIR}
${CMAKE_SOURCE_DIR}/test/*.cpp
${CMAKE_SOURCE_DIR}/test/t/*/reader_test_cases.cpp
${CMAKE_SOURCE_DIR}/test/t/*/writer_test_cases.cpp
${CMAKE_SOURCE_DIR}/test/unit/*.cpp
${CMAKE_SOURCE_DIR}/tools/*.cpp
)
add_dependencies(clang-tidy writer_tests)
else()
message(STATUS "Looking for clang-tidy - not found")
message(STATUS " Build target 'clang-tidy' will not be available.")
endif()
The text was updated successfully, but these errors were encountered:
ffontaine
added a commit
to ffontaine/protozero
that referenced
this issue
Feb 16, 2022
Don't check for protobuf if tests are disabled. As a side effect, this
will avoid a build failure if clang-tidy and protobuf are found but
tests are disabled
Fixmapbox#109
Signed-off-by: Fabrice Fontaine <[email protected]>
writer_tests
used inadd_dependencies
does only exist if tests are enabled. Add an additionalAND BUILD_TESTING
:The text was updated successfully, but these errors were encountered: