Skip to content

Commit 0b9acdb

Browse files
authored
Workaround broken GitHub runner images (microsoft#6683)
This PR contains two changes: 1) Moves a pragma to disable a warning, which seems to be required by the new compiler. 2) Adds a preprocessor define to workaround the crashes caused by the runner image mismatching C++ runtime versions. The second change we will want to revert once the runner images are fixed. The issue tracking the runner images is: actions/runner-images#10004 Related microsoft#6668
1 parent 4b7993c commit 0b9acdb

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,12 @@ if(WIN32 AND NOT (CMAKE_C_COMPILER_ARCHITECTURE_ID MATCHES "ARM.*"))
120120
add_link_options(/CETCOMPAT)
121121
endif()
122122

123+
# This is a hack workaround for the broken azure runner images:
124+
# https://github.com/actions/runner-images/issues/10004
125+
if(WIN32)
126+
add_compile_definitions(_DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR)
127+
endif()
128+
123129
# HLSL Change Ends
124130

125131
# HLSL Change Starts - set flag for Appveyor CI

projects/dxilconv/include/ShaderBinary/ShaderBinary.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -378,10 +378,11 @@ class COperandBase {
378378
INT64 m_Value64[2];
379379
double m_Valued[2];
380380
};
381+
382+
#pragma warning(suppress : 4201) // Warning about nameless structure.
381383
struct {
382384
D3D10_SB_OPERAND_INDEX_REPRESENTATION m_IndexType[3];
383385
D3D10_SB_OPERAND_INDEX_DIMENSION m_IndexDimension;
384-
#pragma warning(suppress : 4201) // Warning about nameless structure.
385386
};
386387

387388
friend class CShaderAsm;

0 commit comments

Comments
 (0)