-
Notifications
You must be signed in to change notification settings - Fork 611
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
CMake: Handle Dependency Checks With Newer Protobuf #6609
Merged
PeterJohnson
merged 5 commits into
wpilibsuite:main
from
mfisher31:macos-absl-spinloc-wait
May 15, 2024
Merged
CMake: Handle Dependency Checks With Newer Protobuf #6609
PeterJohnson
merged 5 commits into
wpilibsuite:main
from
mfisher31:macos-absl-spinloc-wait
May 15, 2024
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
mfisher31
changed the title
CMake: macOS: Link With absl_spinlock_wait in glassnt
CMake: Handle Dependency Checks With Newer Protobuf
May 13, 2024
PeterJohnson
approved these changes
May 15, 2024
chauser
pushed a commit
to chauser/allwpilib
that referenced
this pull request
May 30, 2024
Works around a bug on some systems where protobuf does not correctly depend on required absl libraries.
Gold856
added a commit
to Gold856/allwpilib
that referenced
this pull request
Jun 22, 2024
…suite#6609)" This reverts commit b0d3bf4.
Gold856
added a commit
to Gold856/allwpilib
that referenced
this pull request
Jun 22, 2024
…suite#6609)" This reverts commit b0d3bf4.
PeterJohnson
pushed a commit
that referenced
this pull request
Jun 28, 2024
Reverts #6609 since that fix didn't Just Work(tm) on Windows. (edit: or Ubuntu. Seems to have broken everything except macOS.) This PR configures CMake to try and find protobuf-config.cmake first, which allows protobuf to pull in abseil for us. If protobuf-config.cmake is not available (coprocessors which don't have a new enough protobuf installed are a common case), it will fallback to CMake's built-in FindProtobuf module, which is what we were using before. Add wpi::CreateMessage, a wrapper with an ifdef to switch between Arena::CreateMessage and Arena::Create, since the former is deprecated in newer versions of protobuf. This allows forward compatibility with newer versions of protobuf.
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 fix works fine with homebrew installed protobuf on macOS v14.4.1. It, checks for the Absl cmake package in addition to protobuf which is needed by glassnt + modern macOS.
see #6607
Draft until I can check behavior on windows and linux. The Absl check might need to be a homebrew/mac-only dependency.