diff options
author | Dylan Baker <dylan@pnwbakers.com> | 2021-09-21 10:30:53 -0700 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2022-03-02 19:59:45 +0200 |
commit | f9bfeb2add70973113ab4a98454a5c5d7e3a26ae (patch) | |
tree | 5a9a9d2eb1f0c31c8b5a9002a9333105a92a2508 /mesonbuild | |
parent | 4934b9968aefb69a09d4629b766a1c720c5fa722 (diff) | |
download | meson-f9bfeb2add70973113ab4a98454a5c5d7e3a26ae.zip meson-f9bfeb2add70973113ab4a98454a5c5d7e3a26ae.tar.gz meson-f9bfeb2add70973113ab4a98454a5c5d7e3a26ae.tar.bz2 |
compilers/gnu: set level 0 optimization to '-O0'
GCC with optimization set to 0 does not actually result in no
optimizations, which can be annoying when trying to use a debugger like
gdb, and finding that your variable has been optimized out. We already
do this with clang, so gcc is a bit of an outlier here.
Diffstat (limited to 'mesonbuild')
-rw-r--r-- | mesonbuild/compilers/mixins/gnu.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/compilers/mixins/gnu.py b/mesonbuild/compilers/mixins/gnu.py index ea3aab4..b91788c 100644 --- a/mesonbuild/compilers/mixins/gnu.py +++ b/mesonbuild/compilers/mixins/gnu.py @@ -55,7 +55,7 @@ gnulike_buildtype_args = { } # type: T.Dict[str, T.List[str]] gnu_optimization_args = { - '0': [], + '0': ['-O0'], 'g': ['-Og'], '1': ['-O1'], '2': ['-O2'], |