Skip to content

Commit

Permalink
Add cargo config for linker arch
Browse files Browse the repository at this point in the history
  • Loading branch information
ostenbom committed May 4, 2023
1 parent 60a1083 commit ccdedf6
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 15 deletions.
2 changes: 2 additions & 0 deletions .cargo/config.github
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[target.aarch64-unknown-linux-gnu]
linker = "aarch64-linux-gnu-gcc"
24 changes: 9 additions & 15 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,23 +25,16 @@ jobs:
target: aarch64-unknown-linux-gnu
linker: gcc-aarch64-linux-gnu
cross: true
# - build: arm-v7
# os: ubuntu-latest
# rust: stable
# target: armv7-unknown-linux-gnueabihf
# linker: gcc-arm-linux-gnueabihf
# cross: true
# - build: aarch64
# os: ubuntu-latest
# rust: stable
# target: aarch64-unknown-linux-gnu
# linker: gcc-aarch64-linux-gnu
# cross: true
- build: macos
os: macos-latest
rust: stable
target: x86_64-apple-darwin
cross: false
- build: macos-aarch64
os: macos-latest
rust: stable
target: aarch64-apple-darwin
cross: false
steps:
- name: Checkout repository
uses: actions/checkout@v2
Expand All @@ -61,8 +54,10 @@ jobs:
- name: Install Linker
if: matrix.cross
run: |
cargo install cross
sudo apt update
sudo apt install -y ${{ matrix.linker }}
cat .cargo/config.github >> .cargo/config
- name: Install Rust
run: |
Expand All @@ -89,8 +84,8 @@ jobs:
cp target/${{ matrix.target }}/release/linkup $stage/
cd $stage
RELEASE_VERSION=${GITHUB_REF#refs/tags/}
ASSET_NAME="sysit-$RELEASE_VERSION-${{ matrix.target }}.tar.gz"
RELEASE_VERSION=${{ github.event.inputs.tag }}
ASSET_NAME="linkup-$RELEASE_VERSION-${{ matrix.target }}.tar.gz"
ASSET_PATH="$src/$ASSET_NAME"
CHECKSUM_PATH="$ASSET_PATH.sha256"
Expand All @@ -112,7 +107,6 @@ jobs:
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
tag_name: ${{ github.event.inputs.tag }}
files: |
Expand Down

0 comments on commit ccdedf6

Please sign in to comment.