-
-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: use higher priority when installing llvm alternatives
before this change, gcc and g++ are installed using `updateAptAlternatives()` with the same priority of 40 when they are installed along with ld and libstdc++ as the dependencies of clang and llvm. but both gcc and clang are installed using the same priority of 40 on ubuntu, and the same applies to g++ and clang++. this renders it impossible to use the default compilers of cc and cxx when clang/llvm is installed using setup-cpp on an ubuntu host, as gcc is always prefered over clang by the update-alternatives, as their priorities are identical. in this change, the "priority" parameter is added to the setupGcc(), so that we can specify a different priority when installing llvm. strictly speaking, this is not necessary. as we can just use a higher priority when calling updateAptAlternatives() in llvm/llvm.ts. but by making it more explicit, we can ensure that we always prefer llvm over gcc when installing llvm. Signed-off-by: Kefu Chai <[email protected]>
- Loading branch information
Showing
3 changed files
with
20 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters