Added building helper scripts
This commit is contained in:
parent
f8ddcacf73
commit
5f8293095d
2 changed files with 24 additions and 0 deletions
4
build/01_init.sh
Executable file
4
build/01_init.sh
Executable file
|
@ -0,0 +1,4 @@
|
|||
#!/bin/sh
|
||||
p=$(dirname "$0")
|
||||
apk update && apk add bash
|
||||
"$p"/install_deps_alpine.sh
|
20
build/02_install_build_compiler.sh
Executable file
20
build/02_install_build_compiler.sh
Executable file
|
@ -0,0 +1,20 @@
|
|||
#!/bin/bash
|
||||
if [ $# -ne 1 ];then
|
||||
echo "Missing arch"
|
||||
exit 1
|
||||
fi
|
||||
ARCH="${1,,}"
|
||||
case $ARCH in
|
||||
x86|x86_64|i686|arm|armhf|aarch64)
|
||||
ARCH="${ARCH}-linux-musl"
|
||||
;;
|
||||
*)
|
||||
echo "Invalid arch ${ARCH}"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
HOST=http://musl.cc
|
||||
cd /
|
||||
curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz
|
||||
tar -xf ${ARCH}-cross.tgz
|
||||
rm ${ARCH}-cross.tgz
|
Loading…
Reference in a new issue