Skip to content

Commit 7241c8b

Browse files
authored
Merge pull request #24 from atinm/master
Added Dockerfile.aarch64 and build file to build for Raspberry Pi
2 parents 7ff76b5 + 5bbef4e commit 7241c8b

File tree

4 files changed

+26
-3
lines changed

4 files changed

+26
-3
lines changed

.github/workflows/rust.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,6 @@ jobs:
2020
- name: Install dependencies
2121
run: brew install jack sdl2
2222
- name: Build
23-
run: cargo build -v
23+
run: RUSTFLAGS="-L $(brew --prefix)/lib" cargo build -v
2424
- name: Run tests
25-
run: cargo test --verbose
25+
run: RUSTFLAGS="-L $(brew --prefix)/lib" cargo test --verbose

Dockerfile.aarch64

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
FROM rust:latest
2+
3+
RUN apt update && apt upgrade -y
4+
RUN apt install -y g++-aarch64-linux-gnu libc6-dev-arm64-cross
5+
RUN rustup target add aarch64-unknown-linux-gnu
6+
RUN rustup toolchain install stable-aarch64-unknown-linux-gnu
7+
RUN DEBIAN_FRONTEND='noninteractive' apt install -y jackd2:arm64 libjack-jackd2-dev:arm64 libgl1-mesa-dev:arm64 libsdl2-dev:arm64
8+
RUN DEBIAN_FRONTEND='noninteractive' apt install -y python2 python ninja-build
9+
RUN apt install -y clang:arm64
10+
11+
WORKDIR /app
12+
13+
ENV CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-linux-gnu-gcc \
14+
CC_aarch64_unknown_linux_gnu=aarch64-linux-gnu-gcc \
15+
CXX_aarch64_unknown_linux_gnu=aarch64-linux-gnu-g++ \
16+
SKIA_NINJA_COMMAND=/usr/bin/ninja \
17+
CC=clang \
18+
CXX=clang++
19+
20+
CMD ["cargo", "build", "--target", "aarch64-unknown-linux-gnu", "--release"]

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Loopers
22

3-
![master status](https://github.com/mwylde/loopers/workflows/Rust/badge.svg?branch=master)
3+
![master status](https://github.com/atinm/loopers/workflows/Rust/badge.svg?branch=master)
44
[![Crate](https://img.shields.io/crates/v/loopers.svg)](https://crates.io/crates/loopers)
55

66
Loopers is a graphical [live looper](http://www.livelooping.org/),

build-rasp-aarch64.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/bash
2+
docker build . -t rust_cross_compile/aarch64 -f Dockerfile.aarch64
3+
docker run --rm -ti -v `pwd`:/app rust_cross_compile/aarch64

0 commit comments

Comments
 (0)