Skip to content

Commit

Permalink
add 386, arm, and arm64 to ubuntu buildscripts
Browse files Browse the repository at this point in the history
current use of 64 and 32 in github actions is unaffected and will function as before

added arm, and arm64 as acceptable TARGET_ARCH options
  • Loading branch information
theofficialgman committed May 7, 2022
1 parent eda48e6 commit 5a46bd6
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 6 deletions.
18 changes: 18 additions & 0 deletions dependencies.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,24 @@
"name": "git-lfs-linux-amd64-v3.1.2.tar.gz",
"checksum": "a10bb562658a65ad0e22f331bc43f2cb292a57d21c5b26f52794257e48fcbe10"
},
{
"platform": "linux",
"arch": "386",
"name": "git-lfs-linux-386-v3.1.2.tar.gz",
"checksum": "5fe6c7cf76a218e2e0bbb8c34344981a5cb77774bbb99d1e8986e0967d061015"
},
{
"platform": "linux",
"arch": "arm64",
"name": "git-lfs-linux-arm64-v3.1.2.tar.gz",
"checksum": "c6152c4e24e0575396ee80be8049bf258659fec552f81b410705beed25712ba0"
},
{
"platform": "linux",
"arch": "arm",
"name": "git-lfs-linux-arm-v3.1.2.tar.gz",
"checksum": "cbe2c3e2effa7b168876c9104247f4c5328abadf4a2e3019707510255e7bf46a"
},
{
"platform": "windows",
"arch": "x86",
Expand Down
13 changes: 7 additions & 6 deletions script/build-ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,12 @@ if [[ -z "${CURL_INSTALL_DIR}" ]]; then
exit 1
fi

if [ "$TARGET_ARCH" = "64" ]; then
DEPENDENCY_ARCH="amd64"
else
DEPENDENCY_ARCH="x86"
fi
case "$TARGET_ARCH" in
"64") DEPENDENCY_ARCH="amd64" ;;
"arm64") DEPENDENCY_ARCH="arm64" ;;
"arm") DEPENDENCY_ARCH="arm" ;;
*) DEPENDENCY_ARCH="386" ;;
esac

CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
GIT_LFS_VERSION="$(jq --raw-output '.["git-lfs"].version[1:]' dependencies.json)"
Expand Down Expand Up @@ -72,7 +73,7 @@ DESTDIR="$DESTINATION" \
if [[ "$GIT_LFS_VERSION" ]]; then
echo "-- Bundling Git LFS"
GIT_LFS_FILE=git-lfs.tar.gz
GIT_LFS_URL="https://github.com/git-lfs/git-lfs/releases/download/v${GIT_LFS_VERSION}/git-lfs-linux-amd64-v${GIT_LFS_VERSION}.tar.gz"
GIT_LFS_URL="https://github.com/git-lfs/git-lfs/releases/download/v${GIT_LFS_VERSION}/git-lfs-linux-${DEPENDENCY_ARCH}-v${GIT_LFS_VERSION}.tar.gz"
echo "-- Downloading from $GIT_LFS_URL"
curl -sL -o $GIT_LFS_FILE "$GIT_LFS_URL"
COMPUTED_SHA256=$(compute_checksum $GIT_LFS_FILE)
Expand Down

0 comments on commit 5a46bd6

Please sign in to comment.