-
Notifications
You must be signed in to change notification settings - Fork 219
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: friendlyanon <[email protected]> Co-authored-by: friendlyanon <[email protected]> Co-authored-by: NN <[email protected]> Co-authored-by: NN <[email protected]> Co-authored-by: Zakhar Karlin <[email protected]> Co-authored-by: chausner <[email protected]> Co-authored-by: autoantwort <[email protected]> Co-authored-by: chausner <[email protected]> Co-authored-by: R. Andrew Ohana <[email protected]> Co-authored-by: Mathias Eggert <[email protected]> Co-authored-by: Mathias Eggert <[email protected]> Co-authored-by: Nick <[email protected]> Co-authored-by: gotnone <[email protected]> Co-authored-by: Stanley Pinchak <[email protected]>
- Loading branch information
1 parent
944a65f
commit 7a88f54
Showing
51 changed files
with
1,014 additions
and
843 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: Fetch GCC | ||
description: Puts gcc's path into the output | ||
|
||
inputs: | ||
version: | ||
description: Version of GCC to fetch | ||
required: true | ||
outputs: | ||
gcc: | ||
description: Path of gcc executable | ||
value: ${{ steps.script.outputs.gcc }} | ||
gplusplus: | ||
description: Path of g++ executable | ||
value: ${{ steps.script.outputs.gplusplus }} | ||
|
||
runs: | ||
using: composite | ||
steps: | ||
- id: script | ||
shell: pwsh | ||
run: | | ||
$version = "${{ inputs.version }}" | ||
function Invoke-NativeCommand { | ||
$command = $args[0] | ||
$arguments = $args[1..($args.Length)] | ||
& $command @arguments | ||
if ($LastExitCode -ne 0) { | ||
Write-Error "Exit code $LastExitCode while running $command $arguments" | ||
} | ||
} | ||
if ($IsMacOs) { | ||
Invoke-NativeCommand brew install gcc@${version} | ||
Add-Content "${env:GITHUB_OUTPUT}" "gcc=gcc-${version}" | ||
Add-Content "${env:GITHUB_OUTPUT}" "gplusplus=g++-${version}" | ||
} elseif ($IsLinux) { | ||
# install Homebrew | ||
$env:CI = "1" | ||
Invoke-NativeCommand /bin/bash -c $(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh) | ||
$env:CI = $null | ||
# install gcc | ||
Invoke-NativeCommand /home/linuxbrew/.linuxbrew/bin/brew install gcc@${version} | ||
Add-Content "${env:GITHUB_OUTPUT}" "gcc=/home/linuxbrew/.linuxbrew/bin/gcc-${version}" | ||
Add-Content "${env:GITHUB_OUTPUT}" "gplusplus=/home/linuxbrew/.linuxbrew/bin/g++-${version}" | ||
} elseif ($IsWindows) { | ||
Write-Error "GCC installation on Windows is not supported" | ||
} |
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
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
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
Oops, something went wrong.