Initial commit

This commit is contained in:
Dave Rolsky
2023-03-05 10:57:05 -06:00
commit 1de497cb95
6 changed files with 317 additions and 0 deletions

18
set-cross-compile.sh Executable file
View File

@@ -0,0 +1,18 @@
set -e
set -x
TARGET="$1"
# On macOS and Windows, we can cross-compile to all possible targets without
# using cross.
if uname -a | grep --quiet --extended-regexp -i "darwin|msys|windows"; then
echo "needs-cross=false" >> $GITHUB_OUTPUT
exit 0
fi
if echo "$TARGET" | grep --quiet --extended-regexp -i '(x86_64|586|686).+linux-(gnu|musl)'; then
echo "needs-cross=false" >> $GITHUB_OUTPUT
exit 0
fi
echo "needs-cross=true" >> $GITHUB_OUTPUT