.cargo/config.toml for specifying linker

To avoid code duplication we specify the linker for the specific
target armv7-unknown-linux-gnueabihf in the config.toml file as
specified here:
https://doc.rust-lang.org/cargo/reference/config.html#targettriplelinker
pull/311/head
Daniel Karzel 3 years ago
parent 6e09653d3f
commit f8360fe853

@ -0,0 +1,2 @@
[target.armv7-unknown-linux-gnueabihf]
linker = "arm-linux-gnueabihf-gcc"

@ -64,8 +64,6 @@ jobs:
sudo apt-get install gcc-arm-linux-gnueabihf
- name: Build binary
env:
CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABIHF_LINKER: arm-linux-gnueabihf-gcc
run: |
cargo build -p swap --target ${{ matrix.target }}
@ -100,8 +98,6 @@ jobs:
- uses: Swatinem/rust-cache@v1.2.0
- name: Build tests
env:
CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABIHF_LINKER: arm-linux-gnueabihf-gcc
run: cargo build --tests --workspace --all-features
- name: Run monero-harness tests

@ -55,8 +55,7 @@ jobs:
sudo apt-get install gcc-arm-linux-gnueabihf
- name: Build ${{ matrix.target }} ${{ matrix.bin }} release binary
env:
CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABIHF_LINKER: arm-linux-gnueabihf-gcc
run: cargo build --target=${{ matrix.target }} --release --package swap --bin ${{ matrix.bin }}
- name: Smoke test the binary

Loading…
Cancel
Save