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

Set _DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR when building on windows #449

Merged
merged 2 commits into from
Sep 11, 2024

Conversation

emlowe
Copy link
Contributor

@emlowe emlowe commented Sep 10, 2024

There was a change in VS 2022 to make VS more compliant with the C++ standard and make std::mutex a constexpr.
However, this causes problems if an older version of the runtime is loaded first - in which case, the chiapos wheel will often crash.

https://stackoverflow.com/questions/78598141/first-stdmutexlock-crashes-in-application-built-with-latest-visual-studio

Set _DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR in order to disable the newer (albeit more compliant) code and use the more compatible version

Copy link

Pull Request Test Coverage Report for Build 10799953900

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 79.028%

Totals Coverage Status
Change from base Build 10691731730: 0.0%
Covered Lines: 3497
Relevant Lines: 4425

💛 - Coveralls

@emlowe emlowe marked this pull request as ready for review September 10, 2024 20:40
Copy link
Contributor

@wjblanke wjblanke left a comment

Choose a reason for hiding this comment

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

aok! go microsoft!

Copy link
Contributor

@arvidn arvidn left a comment

Choose a reason for hiding this comment

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

nice one Earle!

@emlowe emlowe merged commit 136616d into main Sep 11, 2024
50 checks passed
@emlowe emlowe deleted the EL.constexpr-mutex branch September 11, 2024 18:27
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

Successfully merging this pull request may close these issues.

3 participants