Skip to content

Commit

Permalink
Add a workaround for MSVC/GH fuckup
Browse files Browse the repository at this point in the history
Visual C++ devs (Microsoft) did something idiotic, and made it so that
if code compiled with the latest compiler runs against an older
runtime it ... crashes without any message.

https://developercommunity.visualstudio.com/t/Access-violation-in-_Thrd_yield-after-up/10664660#T-N10668856

Then Github (Microsoft) shipped an image with a new compiler and an
old runtime, so that compiling anything and trying to run it fails

actions/runner-images#10004

Truly extraordinary
  • Loading branch information
randombit committed Jun 7, 2024
1 parent bf8bbee commit da94668
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/scripts/ci_build.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,10 @@ def sanitize_kv(some_string):
for flag in extra_cxxflags:
flags += ['--extra-cxxflags=%s' % (flag)]

if target_os == 'windows':
# Workaround for https://github.com/actions/runner-images/issues/10004
flags += ['--extra-cxxflags=/D_DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR']

if target in ['minimized']:
flags += ['--minimized-build', '--enable-modules=system_rng,sha2_32,sha2_64,aes']

Expand Down

0 comments on commit da94668

Please sign in to comment.