Skip to content

Commit e317fc8

Browse files
authored
Merge pull request #210 from kleisauke/patch-2
Problem: tests are always building
2 parents 60f7753 + 0611afe commit e317fc8

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

CMakeLists.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,5 +76,9 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}Config.cmake
7676
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/libzmq-pkg-config/FindZeroMQ.cmake
7777
DESTINATION ${CPPZMQ_CMAKECONFIG_INSTALL_DIR}/libzmq-pkg-config)
7878

79-
enable_testing()
80-
add_subdirectory(tests)
79+
option(CPPZMQ_BUILD_TESTS "Whether or not to build the tests" ON)
80+
81+
if (CPPZMQ_BUILD_TESTS)
82+
enable_testing()
83+
add_subdirectory(tests)
84+
endif()

0 commit comments

Comments
 (0)