File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -201,6 +201,9 @@ function(_add_target_variant_c_compile_flags)
201
201
else ()
202
202
list (APPEND result "-g" )
203
203
endif ()
204
+ elseif ("${CFLAGS_BUILD_TYPE} " STREQUAL "MinSizeRel" )
205
+ # MinSizeRel builds of stdlib (but not the compiler) should get debug info
206
+ list (APPEND result "-g" )
204
207
else ()
205
208
list (APPEND result "-g0" )
206
209
endif ()
Original file line number Diff line number Diff line change @@ -246,6 +246,9 @@ function(_add_target_variant_swift_compile_flags
246
246
is_build_type_with_debuginfo ("${build_type} " debuginfo )
247
247
if (debuginfo )
248
248
list (APPEND result "-g" )
249
+ elseif ("${build_type} " STREQUAL "MinSizeRel" )
250
+ # MinSizeRel builds of stdlib should get debug info
251
+ list (APPEND result "-g" )
249
252
endif ()
250
253
251
254
if (enable_assertions )
You can’t perform that action at this time.
0 commit comments