Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Backports:SLE-15-SP6
gnucash
gnucash-4.1-fix-gtest-path.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File gnucash-4.1-fix-gtest-path.patch of Package gnucash
--- gnucash-4.1/common/cmake_modules/GncAddTest.cmake.orig 2020-08-02 21:15:33.177983850 +0200 +++ gnucash-4.1/common/cmake_modules/GncAddTest.cmake 2020-08-08 10:13:40.567411650 +0200 @@ -130,13 +130,17 @@ function(gnc_gtest_configure) unset(GTEST_SRC_DIR CACHE) if (GTEST_ROOT) find_path(GTEST_SRC_DIR src/gtest-all.cc NO_CMAKE_SYSTEM_PATH - PATHS ${GTEST_ROOT}/googletest) + PATHS ${GTEST_ROOT}) endif() if (GTEST_SRC_DIR) - if (EXISTS ${GTEST_SRC_DIR}/include/gtest/gtest.h) - set(GTEST_INCLUDE_DIR ${GTEST_SRC_DIR}/include CACHE PATH "" FORCE) + if (EXISTS ${GTEST_SRC_DIR}/googletest/include/gtest/gtest.h) + set(GTEST_INCLUDE_DIR ${GTEST_SRC_DIR}/googletest/include CACHE PATH "" FORCE) else() - message(FATAL_ERROR "GTEST sources found, but it doesn't have 'gtest/gtest.h'") + if (EXISTS ${GTEST_SRC_DIR}/gtest.h) + set(GTEST_INCLUDE_DIR ${GTEST_SRC_DIR} CACHE PATH "" FORCE) + else() + message(FATAL_ERROR "GTEST sources found, but it doesn't have 'gtest/gtest.h'") + endif() endif() else() if (GTEST_ROOT) @@ -168,15 +172,24 @@ function(gnc_gtest_configure) message(STATUS "Checking for GMOCK") unset(GMOCK_SRC_DIR CACHE) - if (GTEST_ROOT) + if (GMOCK_ROOT) find_path(GMOCK_SRC_DIR src/gmock-all.cc NO_CMAKE_SYSTEM_PATH - PATHS ${GTEST_ROOT}/googlemock) + PATHS ${GMOCK_ROOT}) + else() + if (GTEST_ROOT) + find_path(GMOCK_SRC_DIR src/gmock-all.cc NO_CMAKE_SYSTEM_PATH + PATHS ${GTEST_ROOT}/googlemock) + endif() endif() if (GMOCK_SRC_DIR) if (EXISTS ${GMOCK_SRC_DIR}/include/gmock/gmock.h) set(GMOCK_INCLUDE_DIR ${GMOCK_SRC_DIR}/include CACHE PATH "" FORCE) else() - message(FATAL_ERROR "GMOCK sources found, but it doesn't have 'gmock/gmock.h'") + if (EXISTS ${GMOCK_SRC_DIR}/gmock.h) + set(GMOCK_INCLUDE_DIR ${GMOCK_SRC_DIR} CACHE PATH "" FORCE) + else() + message(FATAL_ERROR "GMOCK sources found, but it doesn't have 'gmock/gmock.h'") + endif() endif() else() if (GTEST_ROOT)
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor