New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
super: fix GCC linkage issue in Linux #11459
Conversation
Review period will end on 2021-06-01 at 00:00:00 UTC. |
This is my second attempt to fix the issues relating to GCC linker flag ordering in the superenv in Linux. To recap why we need this:
This PR implements a solution suggested by @Bo98 to add some additional logic to check if the compiler being used is GCC, and if so, to add the LDFLAG for the newer GCC before I have tested this on a system with brewed GCC 5 while building a package with a newer brewed GCC, and it works as expected. Let me know if this needs further explanation as this is a particularly arcane problem! |
Review period skipped due to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good so far!
Library/Homebrew/extend/ENV/super.rb
Outdated
] | ||
paths = [] | ||
if compiler.match?(GNU_GCC_REGEXP) | ||
f = gcc_version_formula(compiler.to_s) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to catch the FormulaUnavailableError
here in case it doesn't exist.
brew style
with your changes locally?brew typecheck
with your changes locally?brew tests
with your changes locally?