mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-26 00:03:09 -06:00
Bash is a single-pass language
This commit is contained in:
parent
bbf10a9c0b
commit
83e3f29515
26
.github/workflows/get-compiler.sh
vendored
26
.github/workflows/get-compiler.sh
vendored
|
|
@ -1,18 +1,6 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -eu
|
set -eu
|
||||||
|
|
||||||
case "$1" in
|
|
||||||
"pkgs")
|
|
||||||
get_pkgs
|
|
||||||
;;
|
|
||||||
"ccomp")
|
|
||||||
get_compiler
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
exit 1
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
# Given a GOARCH target, return the GCC for that target.
|
# Given a GOARCH target, return the GCC for that target.
|
||||||
function get_compiler() {
|
function get_compiler() {
|
||||||
case "$GOARCH" in
|
case "$GOARCH" in
|
||||||
|
|
@ -44,4 +32,16 @@ function get_pkgs() {
|
||||||
# We (currently) don't need to install more packages on amd64.
|
# We (currently) don't need to install more packages on amd64.
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
"pkgs")
|
||||||
|
get_pkgs
|
||||||
|
;;
|
||||||
|
"ccomp")
|
||||||
|
get_compiler
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
Loading…
Reference in a new issue