mirror of
https://github.com/systemd/systemd.git
synced 2024-10-28 11:55:44 +03:00
sd-boot: Only disable optimization on debug builds
This commit is contained in:
parent
b7db8b7b13
commit
9ea4d81c12
@ -113,7 +113,6 @@ if have_gnu_efi
|
||||
'-Wextra',
|
||||
'-std=gnu90',
|
||||
'-nostdinc',
|
||||
'-ggdb', '-O0',
|
||||
'-fpic',
|
||||
'-fshort-wchar',
|
||||
'-ffreestanding',
|
||||
@ -138,6 +137,13 @@ if have_gnu_efi
|
||||
if get_option('werror') == true
|
||||
compile_args += ['-Werror']
|
||||
endif
|
||||
if get_option('buildtype') == 'debug'
|
||||
compile_args += ['-ggdb', '-O0']
|
||||
elif get_option('buildtype') == 'debugoptimized'
|
||||
compile_args += ['-ggdb', '-Og']
|
||||
else
|
||||
compile_args += ['-O2']
|
||||
endif
|
||||
|
||||
efi_ldflags = ['-T',
|
||||
join_paths(efi_ldsdir, arch_lds),
|
||||
|
Loading…
Reference in New Issue
Block a user