Skip to content

Commit

Permalink
feat: Add aarch64-unknown-linux-gnu binary release
Browse files Browse the repository at this point in the history
  • Loading branch information
hustcer committed May 24, 2022
1 parent cdb551a commit 01cb196
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 4 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ jobs:
- x86_64-pc-windows-msvc
- x86_64-unknown-linux-musl
- x86_64-unknown-linux-gnu
- aarch64-unknown-linux-gnu
include:
- target: aarch64-apple-darwin
os: macos-latest
Expand All @@ -37,6 +38,9 @@ jobs:
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
target_rustflags: ''
- target: aarch64-unknown-linux-gnu
os: ubuntu-latest
target_rustflags: ''

runs-on: ${{matrix.os}}

Expand Down
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
# Changelog
All notable changes to this project will be documented in this file.

## [0.2.1] - 2022-05-24

### Features

- Add download m4a format music file support
- Add x86_64-unknown-linux-gnu release target
- Add aarch64-unknown-linux-gnu binary release

## [0.2.0] - 2022-05-21

### Bug Fixes
Expand Down
18 changes: 14 additions & 4 deletions bin/release
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,24 @@ echo "Building $bin..."
if [[ "ubuntu-latest" = $os ]]; then
# musl-tools to fix 'Failed to find tool. Is `musl-gcc` installed?'
sudo apt install musl-tools -y;
# export OPENSSL_DIR="/usr/lib/ssl"
# export OPENSSL_INCLUDE_DIR="/usr/include/openssl"
# export OPENSSL_LIB_DIR="/usr/lib/x86_64-linux-gnu"

cd /usr/share
wget https://www.openssl.org/source/openssl-1.1.1o.tar.gz
tar xzf openssl-1.1.1o.tar.gz
cd openssl-1.1.1o && ./config shared 1>/dev/null && make 1>/dev/null && cd $src

if [[ "aarch64-unknown-linux-gnu" = $target ]]; then
sudo apt-get install gcc-aarch64-linux-gnu -y
cd openssl-1.1.1o
./config shared no-asm no-async --cross-compile-prefix=aarch64-linux-gnu- 1>/dev/null
# Remove `-m64` string in Makefile
sed '/-m64/d' Makefile > Makefile.bk && mv Makefile.bk Makefile
make 1>/dev/null && cd $src
# This is very important here
export CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-linux-gnu-gcc
else
cd openssl-1.1.1o && ./config shared 1>/dev/null && make 1>/dev/null && cd $src
fi

export OPENSSL_LIB_DIR=/usr/share/openssl-1.1.1o/
export OPENSSL_INCLUDE_DIR=/usr/share/openssl-1.1.1o/include
# env
Expand Down

0 comments on commit 01cb196

Please sign in to comment.