Skip to content

Commit

Permalink
Merge pull request #279 from ursfassler/googletest
Browse files Browse the repository at this point in the history
No googletest auto-download
  • Loading branch information
ursfassler authored Dec 30, 2023
2 parents 4d47d6c + 4301045 commit 95e6b70
Show file tree
Hide file tree
Showing 9 changed files with 19 additions and 564 deletions.
11 changes: 2 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.5)
cmake_minimum_required(VERSION 3.9)

if(NOT CMAKE_VERSION VERSION_LESS "3.3")
# Don't ignore visibility related properties for non-SHARED targets
Expand All @@ -14,7 +14,6 @@ endif()
project(Cucumber-Cpp)

option(BUILD_SHARED_LIBS "Generate shared libraries" OFF)
option(CUKE_USE_STATIC_GTEST "Statically link Google Test" ON)
option(CUKE_ENABLE_BOOST_TEST "Enable Boost.Test framework" ON)
option(CUKE_ENABLE_EXAMPLES "Build examples" OFF)
option(CUKE_ENABLE_GTEST "Enable Google Test framework" ON)
Expand All @@ -24,8 +23,6 @@ option(CUKE_CODE_COVERAGE "Enable instrumentation for code coverage" OFF)
set(CUKE_ENABLE_SANITIZER "OFF" CACHE STRING "Sanitizer to use for checking")
set_property(CACHE CUKE_ENABLE_SANITIZER PROPERTY STRINGS OFF "address" "thread" "undefined")
option(CUKE_TESTS_VALGRIND "Enable tests within Valgrind" OFF)
set(GMOCK_SRC_DIR "" CACHE STRING "Google Mock framework sources path (otherwise downloaded)")
set(GMOCK_VER "1.11.0" CACHE STRING "Google Mock framework version to be used")

if(NOT DEFINED CMAKE_CXX_STANDARD)
set(CMAKE_CXX_STANDARD 17)
Expand Down Expand Up @@ -122,11 +119,7 @@ endif()
#

if(CUKE_ENABLE_GTEST)
set(GTEST_USE_STATIC_LIBS ${CUKE_USE_STATIC_GTEST})
if(NOT GMOCK_ROOT)
set(GMOCK_ROOT "${CMAKE_CURRENT_BINARY_DIR}/gmock")
endif()
find_package(GMock REQUIRED)
find_package(GTest 1.11.0)
endif()

#
Expand Down
8 changes: 3 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,15 @@ If you want to contribute code to the project, guidelines are in [CONTRIBUTING.m

It relies on a few executables:

* [cmake](https://cmake.org/download/) 3.5 or later.
* [cmake](https://cmake.org/download/) 3.9 or later.
Required to setup environment and build software

It relies on a few libraries:

* [Asio](https://think-async.com/Asio/) 1.18.1 or later.
* [Boost.Test](http://www.boost.org/) 1.70. Optional for the Boost Test driver.
* [GTest](http://code.google.com/p/googletest/) 1.6 or later.
Optional for the GTest driver. By default downloaded and built by CMake.
* [GMock](http://code.google.com/p/googlemock/) 1.6 or later.
Optional for the internal test suite. By default downloaded and built by CMake.
* [GTest](https://github.com/google/googletest) 1.11.0 or later. Optional for the GTest driver.
* [GMock](https://github.com/google/googletest) 1.11.0 or later. Optional for the internal test suite.
* [nlohmann-json](https://github.com/nlohmann/json) 3.10.5 or later.
* [Qt 4 or 5](http://qt-project.org/). Optional for the CalcQt example and QtTest driver (only Qt 5).
* [TCLAP](https://tclap.sourceforge.net/) 1.2.5 or later.
Expand Down
Loading

0 comments on commit 95e6b70

Please sign in to comment.