Merge pull request #14686 from MikeMcQuaid/build_from_source_warnings
Warn more when building from source
This commit is contained in:
commit
25bf83e58d
@ -162,7 +162,7 @@ rescue BuildError => e
|
|||||||
This build failure is expected behaviour.
|
This build failure is expected behaviour.
|
||||||
Do not create issues about this on Homebrew's GitHub repositories.
|
Do not create issues about this on Homebrew's GitHub repositories.
|
||||||
Any opened issues will be immediately closed without response.
|
Any opened issues will be immediately closed without response.
|
||||||
Do not ask for help from MacHomebrew on Twitter.
|
Do not ask for help from Homebrew or its maintainers on social media.
|
||||||
You may ask for help in Homebrew's discussions but are unlikely to receive a response.
|
You may ask for help in Homebrew's discussions but are unlikely to receive a response.
|
||||||
Try to figure out the problem yourself and submit a fix as a pull request.
|
Try to figure out the problem yourself and submit a fix as a pull request.
|
||||||
We will review it but may or may not accept it.
|
We will review it but may or may not accept it.
|
||||||
|
|||||||
@ -198,9 +198,8 @@ module Homebrew
|
|||||||
|
|
||||||
# if the user's flags will prevent bottle only-installations when no
|
# if the user's flags will prevent bottle only-installations when no
|
||||||
# developer tools are available, we need to stop them early on
|
# developer tools are available, we need to stop them early on
|
||||||
unless DevelopmentTools.installed?
|
|
||||||
build_flags = []
|
build_flags = []
|
||||||
|
unless DevelopmentTools.installed?
|
||||||
build_flags << "--HEAD" if args.HEAD?
|
build_flags << "--HEAD" if args.HEAD?
|
||||||
build_flags << "--build-bottle" if args.build_bottle?
|
build_flags << "--build-bottle" if args.build_bottle?
|
||||||
build_flags << "--build-from-source" if args.build_from_source?
|
build_flags << "--build-from-source" if args.build_from_source?
|
||||||
@ -208,6 +207,11 @@ module Homebrew
|
|||||||
raise BuildFlagsError.new(build_flags, bottled: formulae.all?(&:bottled?)) if build_flags.present?
|
raise BuildFlagsError.new(build_flags, bottled: formulae.all?(&:bottled?)) if build_flags.present?
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if build_flags.present? && !Homebrew::EnvConfig.developer?
|
||||||
|
opoo "building from source is not supported!"
|
||||||
|
puts "You're on your own. Failures are expected so don't create any issues, please!"
|
||||||
|
end
|
||||||
|
|
||||||
installed_formulae = formulae.select do |f|
|
installed_formulae = formulae.select do |f|
|
||||||
Install.install_formula?(
|
Install.install_formula?(
|
||||||
f,
|
f,
|
||||||
|
|||||||
@ -97,10 +97,17 @@ module Homebrew
|
|||||||
formulae, casks = args.named.to_formulae_and_casks(method: :resolve)
|
formulae, casks = args.named.to_formulae_and_casks(method: :resolve)
|
||||||
.partition { |o| o.is_a?(Formula) }
|
.partition { |o| o.is_a?(Formula) }
|
||||||
|
|
||||||
if args.build_from_source? && !DevelopmentTools.installed?
|
if args.build_from_source?
|
||||||
|
unless DevelopmentTools.installed?
|
||||||
raise BuildFlagsError.new(["--build-from-source"], bottled: formulae.all?(&:bottled?))
|
raise BuildFlagsError.new(["--build-from-source"], bottled: formulae.all?(&:bottled?))
|
||||||
end
|
end
|
||||||
|
|
||||||
|
unless Homebrew::EnvConfig.developer?
|
||||||
|
opoo "building from source is not supported!"
|
||||||
|
puts "You're on your own. Failures are expected so don't create any issues, please!"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
Install.perform_preinstall_checks
|
Install.perform_preinstall_checks
|
||||||
|
|
||||||
formulae.each do |formula|
|
formulae.each do |formula|
|
||||||
|
|||||||
@ -125,10 +125,17 @@ module Homebrew
|
|||||||
def upgrade_outdated_formulae(formulae, args:)
|
def upgrade_outdated_formulae(formulae, args:)
|
||||||
return false if args.cask?
|
return false if args.cask?
|
||||||
|
|
||||||
if args.build_from_source? && !DevelopmentTools.installed?
|
if args.build_from_source?
|
||||||
|
unless DevelopmentTools.installed?
|
||||||
raise BuildFlagsError.new(["--build-from-source"], bottled: formulae.all?(&:bottled?))
|
raise BuildFlagsError.new(["--build-from-source"], bottled: formulae.all?(&:bottled?))
|
||||||
end
|
end
|
||||||
|
|
||||||
|
unless Homebrew::EnvConfig.developer?
|
||||||
|
opoo "building from source is not supported!"
|
||||||
|
puts "You're on your own. Failures are expected so don't create any issues, please!"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
Install.perform_preinstall_checks
|
Install.perform_preinstall_checks
|
||||||
|
|
||||||
if formulae.blank?
|
if formulae.blank?
|
||||||
|
|||||||
@ -118,7 +118,7 @@ module Homebrew
|
|||||||
Do not create any issues about this on Homebrew's GitHub repositories.
|
Do not create any issues about this on Homebrew's GitHub repositories.
|
||||||
Do not create any issues even if you think this message is unrelated.
|
Do not create any issues even if you think this message is unrelated.
|
||||||
Any opened issues will be immediately closed without response.
|
Any opened issues will be immediately closed without response.
|
||||||
Do not ask for help from MacHomebrew on Twitter.
|
Do not ask for help from Homebrew or its maintainers on social media.
|
||||||
You may ask for help in Homebrew's discussions but are unlikely to receive a response.
|
You may ask for help in Homebrew's discussions but are unlikely to receive a response.
|
||||||
Try to figure out the problem yourself and submit a fix as a pull request.
|
Try to figure out the problem yourself and submit a fix as a pull request.
|
||||||
We will review it but may or may not accept it.
|
We will review it but may or may not accept it.
|
||||||
|
|||||||
@ -274,7 +274,7 @@ class FormulaInstaller
|
|||||||
Do not create any issues about failures building from source on Homebrew's GitHub repositories.
|
Do not create any issues about failures building from source on Homebrew's GitHub repositories.
|
||||||
Do not create any issues building from source even if you think this message is unrelated.
|
Do not create any issues building from source even if you think this message is unrelated.
|
||||||
Any opened issues will be immediately closed without response.
|
Any opened issues will be immediately closed without response.
|
||||||
Do not ask for help building from source from MacHomebrew on Twitter.
|
Do not ask for help from Homebrew or its maintainers on social media.
|
||||||
You may ask for help building from source in Homebrew's discussions but are unlikely to receive a response.
|
You may ask for help building from source in Homebrew's discussions but are unlikely to receive a response.
|
||||||
If building from source fails, try to figure out the problem yourself and submit a fix as a pull request.
|
If building from source fails, try to figure out the problem yourself and submit a fix as a pull request.
|
||||||
We will review it but may or may not accept it.
|
We will review it but may or may not accept it.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user