Skip to content

Commit

Permalink
Add i686 linux target
Browse files Browse the repository at this point in the history
  • Loading branch information
alisomay committed Nov 20, 2023
1 parent 1cd7d4a commit 702e380
Show file tree
Hide file tree
Showing 7 changed files with 30 additions and 64 deletions.
11 changes: 8 additions & 3 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,17 @@
linker = "aarch64-linux-gnu-gcc"
rustflags = [
"-C", "link-arg=-Bstatic",
# Other flags as needed
]

[target.armv7-unknown-linux-gnueabihf]
linker = "arm-linux-gnueabihf-gcc"
rustflags = [
"-C", "link-arg=-Bstatic",
# Other flags as needed
]
]

# [target.i686-unknown-linux-gnu]
# linker = "i686-linux-gnu-gcc"
# rustflags = [
# "-C", "link-arg=-Bstatic",
# ]

11 changes: 7 additions & 4 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Tests and release
name: CI/CD
on: [push]
env:
CRATE_NAME: smrec
Expand All @@ -18,6 +18,11 @@ jobs:
target: x86_64-unknown-linux-gnu
bin: smrec
name: smrec-Linux-x86_64-gnu.tar.gz
# - os_name: Linux-i686
# os: ubuntu-latest
# target: i686-unknown-linux-gnu
# bin: smrec
# name: smrec-Linux-i686-gnu.tar.gz

# Linux Gnu Arm
- os_name: Linux-aarch64
Expand Down Expand Up @@ -68,15 +73,13 @@ jobs:
skip_tests: true
toolchain:
- stable
# - beta
# - nightly
steps:
- uses: actions/checkout@v4
- name: Cache cargo & target directories
uses: Swatinem/rust-cache@v2
with:
key: "v2"
# Why?

- name: Configure Git
run: |
git config --global user.email "[email protected]"
Expand Down
22 changes: 9 additions & 13 deletions Cross.toml
Original file line number Diff line number Diff line change
@@ -1,29 +1,25 @@
# [target.aarch64-unknown-linux-gnu.dockerfile]
# file = "./docker/cross/Dockerfile"
# context = "."
# build-args = {}

# [target.armv7-unknown-linux-gnueabihf.dockerfile]
# file = "./docker/cross/Dockerfile"
# context = "."
# build-args = {}
# Install build dependencies for the right architecture per target
# [target.i686-unknown-linux-gnu]
# runner = "qemu-user"
# pre-build = [
# "export BUILDKIT_PROGRESS=plain",
# "dpkg --add-architecture $CROSS_DEB_ARCH",
# "apt-get update && apt-get --assume-yes install libasound2-dev:$CROSS_DEB_ARCH libjack-jackd2-dev:$CROSS_DEB_ARCH"
# ]

[target.aarch64-unknown-linux-gnu]
runner = "qemu-user"
# pre-build = ["export BUILDKIT_PROGRESS=plain"]
pre-build = [
"export BUILDKIT_PROGRESS=plain",
"dpkg --add-architecture $CROSS_DEB_ARCH",
"apt-get update && apt-get --assume-yes install libasound2-dev:$CROSS_DEB_ARCH libjack-jackd2-dev:$CROSS_DEB_ARCH"
]


[target.armv7-unknown-linux-gnueabihf]
runner = "qemu-user"
# pre-build = ["export BUILDKIT_PROGRESS=plain"]

pre-build = [
"export BUILDKIT_PROGRESS=plain",
"dpkg --add-architecture $CROSS_DEB_ARCH",
"apt-get update && apt-get --assume-yes install libasound2-dev:$CROSS_DEB_ARCH libjack-jackd2-dev:$CROSS_DEB_ARCH"
]

44 changes: 0 additions & 44 deletions docker/cross/Dockerfile

This file was deleted.

6 changes: 6 additions & 0 deletions scripts/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Pre build scripts

These are about the become obsolete.
They are here for historical reasons.
Once ` cpal`` publishes a new version, we can remove them.
For linux users, we'll see how it works but I might make a PR to `cpal`` to automate installation of jack and alsa dependencies also if it makes sense.
File renamed without changes.
File renamed without changes.

0 comments on commit 702e380

Please sign in to comment.