Skip to content

Commit a498004

Browse files
authored
Merge pull request #29792 from compnerd/vs2017
build: make building with VS2017 15.8+ work again
2 parents bbd888f + b46ddbe commit a498004

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

cmake/modules/AddSwift.cmake

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -279,6 +279,10 @@ function(_add_variant_c_compile_flags)
279279
list(APPEND result "-D_DLL")
280280
# NOTE: We assume that we are using VS 2015 U2+
281281
list(APPEND result "-D_ENABLE_ATOMIC_ALIGNMENT_FIX")
282+
# NOTE: We use over-aligned values for the RefCount side-table
283+
# (see revision d913eefcc93f8c80d6d1a6de4ea898a2838d8b6f)
284+
# This is required to build with VS2017 15.8+
285+
list(APPEND result "-D_ENABLE_EXTENDED_ALIGNED_STORAGE=1")
282286

283287
# msvcprt's std::function requires RTTI, but we do not want RTTI data.
284288
# Emulate /GR-.

0 commit comments

Comments
 (0)