-
Notifications
You must be signed in to change notification settings - Fork 280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gmock from source on Debian buster #1022
Merged
dirk-thomas
merged 4 commits into
ros:kinetic-devel
from
sloretz:gmock-from-source-buster
Oct 3, 2019
Merged
Gmock from source on Debian buster #1022
dirk-thomas
merged 4 commits into
ros:kinetic-devel
from
sloretz:gmock-from-source-buster
Oct 3, 2019
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
Thank you for this patch! |
Thanks, works like a charm :) |
This was referenced Sep 16, 2019
Thanks for the patch. |
dirk-thomas
reviewed
Oct 10, 2019
mikepurvis
added a commit
to mikepurvis/catkin
that referenced
this pull request
Nov 8, 2019
mikepurvis
added a commit
to mikepurvis/catkin
that referenced
this pull request
Nov 8, 2019
dirk-thomas
pushed a commit
that referenced
this pull request
Nov 16, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This fixes some issues with gmock tests on Debian buster. The
gtest
rosdep key resolves to libgtest-dev on Debian buster. This package depends ongoogletest
, and also installs gtest headers to/usr/include
. The packagegoogletest
includes both gtest and gmock, as source files in/usr/src/googletest/
. Additionally there isFindGTest.cmake
module installed by the packagecmake-data
. This situation tricks the current logic.First the search paths here weren't considering that gtest/gmock could be installed in
/usr/src
. This PR adds those paths.Second Because
GTest
in/usr/include
is found by the cmake module, the logic seesGTEST_FOUND
but notGMOCK_FOUND
. Thefind_package()
'd gtest is used gmock is considered unavailable, but gmock would be available if this code tried to find its sources. This PR refactors the logic to the following:find_package()
, use thatfind_package()
calls.gtest
,gtest_main
,gmock
andgmock_main
targets if they don't exist no matter where we're using gtest/gmock from.