Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change linux binaries generated by release script to use aarch64 suffix instead of arm64 #323

Merged
merged 1 commit into from
May 20, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions make/buf/scripts/release.bash
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,6 @@ goarch() {
esac
}

hostarch() {
case $(uname -m) in
x86_64) echo x86_64 ;;
arm64) echo arm64 ;;
aarch64) echo arm64 ;;
*) return 1 ;;
esac
}

sha256() {
if ! type sha256sum >/dev/null 2>/dev/null; then
if ! type shasum >/dev/null 2>/dev/null; then
Expand Down Expand Up @@ -75,6 +66,9 @@ cd "${RELEASE_DIR}"

for os in Darwin Linux; do
for arch in x86_64 arm64; do
if [ "${os}" == "Linux" ] && [ "${arch}" == "arm64" ]; then
arch="aarch64"
fi
dir="${os}/${arch}/${BASE_NAME}"
mkdir -p "${dir}/bin"
for binary in \
Expand All @@ -92,21 +86,27 @@ done

for os in Darwin Linux; do
for arch in x86_64 arm64; do
if [ "${os}" == "Linux" ] && [ "${arch}" == "arm64" ]; then
arch="aarch64"
fi
dir="${os}/${arch}/${BASE_NAME}"
mkdir -p "${dir}/etc/bash_completion.d"
mkdir -p "${dir}/share/fish/vendor_completions.d"
mkdir -p "${dir}/share/zsh/site-functions"
#mkdir -p "${dir}/share/man/man1"
"$(uname -s)/$(hostarch)/${BASE_NAME}/bin/buf" bash-completion > "${dir}/etc/bash_completion.d/buf"
"$(uname -s)/$(hostarch)/${BASE_NAME}/bin/buf" fish-completion > "${dir}/share/fish/vendor_completions.d/buf.fish"
"$(uname -s)/$(hostarch)/${BASE_NAME}/bin/buf" zsh-completion > "${dir}/share/zsh/site-functions/_buf"
"$(uname -s)/$(uname -m)/${BASE_NAME}/bin/buf" bash-completion > "${dir}/etc/bash_completion.d/buf"
"$(uname -s)/$(uname -m)/${BASE_NAME}/bin/buf" fish-completion > "${dir}/share/fish/vendor_completions.d/buf.fish"
"$(uname -s)/$(uname -m)/${BASE_NAME}/bin/buf" zsh-completion > "${dir}/share/zsh/site-functions/_buf"
#"$(uname -s)/$(uname -m)/${1}/bin/buf" manpages "${dir}/share/man/man1"
cp -R "${DIR}/LICENSE" "${dir}/LICENSE"
done
done

for os in Darwin Linux; do
for arch in x86_64 arm64; do
if [ "${os}" == "Linux" ] && [ "${arch}" == "arm64" ]; then
arch="aarch64"
fi
dir="${os}/${arch}/${BASE_NAME}"
tar_context_dir="$(dirname "${dir}")"
tar_dir="${BASE_NAME}"
Expand Down