synit/synit-pid1/Makefile

28 lines
863 B
Makefile
Raw Normal View History

all:
cargo build --all-targets
x86_64-binary: x86_64-binary-release
2021-10-08 14:47:48 +00:00
x86_64-binary-release:
$(MAKE) -C ../packaging build-image.rust ARCH=x86_64
docker run -i --rm \
-v $(HOME)/.cargo:/home/build/.cargo \
-v `pwd`:/data \
-e CARGO_TARGET_DIR=target/x86_64-unknown-linux-musl \
synit-build-rust:x86_64 \
cargo build --release --all-targets
armv7-binary: armv7-binary-release
armv7-binary-release:
2021-10-08 14:47:48 +00:00
cross build --target=armv7-unknown-linux-musleabihf --release --all-targets
# Hack to workaround https://github.com/rust-embedded/cross/issues/598
HACK_WORKAROUND_ISSUE_598=CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_RUSTFLAGS="-C link-arg=/usr/local/aarch64-linux-musl/lib/libc.a"
aarch64-binary: aarch64-binary-release
aarch64-binary-release:
$(HACK_WORKAROUND_ISSUE_598) \
cross build --target=aarch64-unknown-linux-musl --release --all-targets