Merge pull request #10566 from MikeMcQuaid/undeprecate-env-O
Undeprecate ENV.O1/ENV.O0
This commit is contained in:
commit
1d486249a3
@ -238,7 +238,6 @@ module SharedEnvExtension
|
|||||||
|
|
||||||
# Snow Leopard defines an NCURSES value the opposite of most distros.
|
# Snow Leopard defines an NCURSES value the opposite of most distros.
|
||||||
# @see https://bugs.python.org/issue6848
|
# @see https://bugs.python.org/issue6848
|
||||||
# Currently only used by aalib in core.
|
|
||||||
sig { void }
|
sig { void }
|
||||||
def ncurses_define
|
def ncurses_define
|
||||||
odeprecated "ENV.ncurses_define"
|
odeprecated "ENV.ncurses_define"
|
||||||
|
|||||||
@ -97,7 +97,7 @@ module Stdenv
|
|||||||
old
|
old
|
||||||
end
|
end
|
||||||
|
|
||||||
%w[O3 O2 O1 O0 Os].each do |opt|
|
%w[O3 O2 Os].each do |opt|
|
||||||
define_method opt do
|
define_method opt do
|
||||||
odisabled "ENV.#{opt}"
|
odisabled "ENV.#{opt}"
|
||||||
|
|
||||||
@ -106,6 +106,13 @@ module Stdenv
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
%w[O1 O0].each do |opt|
|
||||||
|
define_method opt do
|
||||||
|
send(:remove_from_cflags, /-O./)
|
||||||
|
send(:append_to_cflags, "-#{opt}")
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
sig { returns(T.any(String, Pathname)) }
|
sig { returns(T.any(String, Pathname)) }
|
||||||
def determine_cc
|
def determine_cc
|
||||||
s = super
|
s = super
|
||||||
|
|||||||
@ -344,7 +344,7 @@ module Superenv
|
|||||||
append_to_cccfg "O"
|
append_to_cccfg "O"
|
||||||
end
|
end
|
||||||
|
|
||||||
%w[O3 O2 O1 O0 Os].each do |opt|
|
%w[O3 O2 Os].each do |opt|
|
||||||
define_method opt do
|
define_method opt do
|
||||||
odisabled "ENV.#{opt}"
|
odisabled "ENV.#{opt}"
|
||||||
|
|
||||||
@ -352,6 +352,12 @@ module Superenv
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
%w[O1 O0].each do |opt|
|
||||||
|
define_method opt do
|
||||||
|
send(:[]=, "HOMEBREW_OPTIMIZATION_LEVEL", opt)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
sig { void }
|
sig { void }
|
||||||
def set_x11_env_if_installed
|
def set_x11_env_if_installed
|
||||||
odisabled "ENV.set_x11_env_if_installed"
|
odisabled "ENV.set_x11_env_if_installed"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user