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

std::mutex problem on windows / msvc 2022 #1227

Open
redhog opened this issue Jan 27, 2025 · 0 comments
Open

std::mutex problem on windows / msvc 2022 #1227

redhog opened this issue Jan 27, 2025 · 0 comments

Comments

@redhog
Copy link

redhog commented Jan 27, 2025

In my plugin (crowdsource_pi), I'm using std::mutex, and this failed on windows (MSVC 2022) with an access violation inside the mutex implementation.

After a lot of digging, I found the culprit to be a version incompatibility between the STL headers of MSVC 2022 and the version of msvcp140.dll, see this thread:

https://developercommunity.visualstudio.com/t/Visual-Studio-17100-Update-leads-to-Pr/10669759

I ended up using the workaround described there (defining _DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR), but I assume this is a problem that might affect more people. I know too little of windows to be sure of the correct solution, but I'm assuming it would be either to distribute the correct version of msvcp140.dll with opencpn, or differentiating the builds for windows installs with different versions of that dll.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant