Skip to content

Commit e67542a

Browse files
committed
build: disable -Og when building with clang
clang does not yet support -Og, fall back to -O0. See: https://llvm.org/bugs/show_bug.cgi?id=20765 Fixes: #1608 PR-URL: #1609 Reviewed-By: Jeremiah Senkpiel <[email protected]>
1 parent 279f611 commit e67542a

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

common.gypi

+6-1
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,13 @@
5454
'v8_enable_handle_zapping%': 1,
5555
},
5656
'defines': [ 'DEBUG', '_DEBUG' ],
57-
'cflags': [ '-g', '-Og' ],
57+
'cflags': [ '-g' ],
5858
'conditions': [
59+
['clang==1', {
60+
'cflags': [ '-O0' ], # https://llvm.org/bugs/show_bug.cgi?id=20765
61+
}, {
62+
'cflags': [ '-Og' ], # Debug-friendly optimizations only.
63+
}],
5964
['target_arch=="x64"', {
6065
'msvs_configuration_platform': 'x64',
6166
}],

0 commit comments

Comments
 (0)