Skip to content
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

Minor fixes for Cartographer from ROS #1705

Merged
merged 3 commits into from
Oct 23, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions cmake/modules/FindGMock.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ if(NOT GMock_FOUND)
EXCLUDE_FROM_ALL)
endif()
set(GMOCK_LIBRARIES gmock_main)
set(GMOCK_INCLUDE_DIRS ${GMOCK_SRC_DIR}/include)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1
I'm working on migrating our fork to Noetic, this was needed there too.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you try installing the libgmock-dev package? I added Ubuntu Focal (which Noetic is primarily targeted at) to CI recently and it passes.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So installing libgmock-dev does make it work. But I actually still think this is a bug, and installing libgmock-dev just works around it.

When you install libgmock-dev, it means you actually don't come in the if(NOT GMOCK_LIBRARIES) block at all, and hence don't build gmock from source. If for some reason you do need to build gmock from source, then this block still doesn't export the GMOCK_INCLUDE_DIRS properly.

Thus, I think we should either keep this fix, or we should remove the fallback to build from source completely.

endif()
endif()

Expand Down
3 changes: 2 additions & 1 deletion package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,10 @@

<build_depend>git</build_depend>
<build_depend>google-mock</build_depend>
<build_depend>gtest</build_depend>
<build_depend>python3-sphinx</build_depend>

<depend>boost</depend>
<depend>libboost-iostreams-dev</depend>
<depend>eigen</depend>
<depend>libcairo2-dev</depend>
<depend>libceres-dev</depend>
MichaelGrupp marked this conversation as resolved.
Show resolved Hide resolved
Expand Down