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

Forced C++20 requirement? #1041

Open
zokrovi opened this issue Sep 9, 2024 · 2 comments
Open

Forced C++20 requirement? #1041

zokrovi opened this issue Sep 9, 2024 · 2 comments
Labels
area: backend backend: crashpad enhancement New feature or request Platform: Native upstream The issue is related to an upstream dependency

Comments

@zokrovi
Copy link

zokrovi commented Sep 9, 2024

Unfortunately, a recent crashpad update (I believe it was 0.7.6) includes changes to mini chromium which now requires C++20 features like std::ranges. I can't see a way to conditionally make mini chromium use pre-C++20 standards.

This effectively hinders adoption and makes it impossible for a large number of projects out there to upgrade beyond sentry-native 0.7.6 as they cannot move on from C++17 yet, short of mirroring and patching mini chromium.

@supervacuus
Copy link
Collaborator

Unfortunately, a recent crashpad update (I believe it was 0.7.6) includes changes to mini chromium which now requires C++20 features like std::ranges. I can't see a way to conditionally make mini chromium use pre-C++20 standards.

While we use a getsentry fork of crashpad, we don't use one for mini_chromium (and instead point the submodule to the upstream Google repo), so whenever crashpad updates its code based on mini_chromium changes (or vice versa, whoever is the driver), we go with the flow. crashpad doesn't generally consider build-tool adoption as a limiting factor since they are their primary user, let alone providing build parameters to minimize their effect.

This is a much bigger topic for Sentry, even though no clear boundary has yet been defined on when to fork mini_chromium for build-tooling compatibility.

This effectively hinders adoption and makes it impossible for a large number of projects out there to upgrade beyond sentry-native 0.7.6 as they cannot move on from C++17 yet, short of mirroring and patching mini chromium.

I fully understand this issue. Sadly, "mirroring and patching" mini_chromium won't suffice since you might also have to track the related changes in crashpad. This is essentially the effort of maintaining an additional transitive dependency fork for Sentry, too, so I cannot guarantee this will happen.

CC: @kahest.

@getsantry getsantry bot removed the status in GitHub Issues with 👀 3 Sep 9, 2024
@supervacuus supervacuus added enhancement New feature or request backend: crashpad area: backend upstream The issue is related to an upstream dependency Platform: Native labels Sep 9, 2024
@sbhorvatic
Copy link

sbhorvatic commented Sep 13, 2024

Having the same error while setting -DCMAKE_CXX_STANDARD=20 as the build still uses C++17. Any other params I can pass to build using C++20?

User error, I am using libc++-14-dev which seem to treat its implementation of ranges as experimental until version 16

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: backend backend: crashpad enhancement New feature or request Platform: Native upstream The issue is related to an upstream dependency
Projects
Status: No status
Status: Backlog
Development

No branches or pull requests

3 participants