init commit

This commit is contained in:
2021-08-14 17:13:45 +02:00
commit 2f7e2ba881
7 changed files with 43 additions and 0 deletions
+4
View File
@@ -0,0 +1,4 @@
[build]
[target.armv7-unknown-linux-gnueabihf]
linker = "arm-linux-gnueabihf-gcc"
+1
View File
@@ -0,0 +1 @@
/target
Generated
+5
View File
@@ -0,0 +1,5 @@
# This file is automatically @generated by Cargo.
# It is not intended for manual editing.
[[package]]
name = "q7s-rs-crosscompile"
version = "0.1.0"
+9
View File
@@ -0,0 +1,9 @@
[package]
name = "q7s-rs-crosscompile"
version = "0.1.0"
authors = ["Robin Mueller <robin.mueller.m@gmail.com>"]
edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
+14
View File
@@ -0,0 +1,14 @@
Cross-compiling Rust for the Raspberry PI
======
# Prerequisites
1. Install standard library
```sh
rustup target add armv7-unknown-linux-gnueabihf
```
2. Install a cross-compile toolchain and add it to your path.
You can download one built with crosstool-ng from
[here](https://www.dropbox.com/sh/hkn4lw87zr002fh/AAAO-HxFQzfmmPQQ9KVmoooGa?dl=0).
Executable
+7
View File
@@ -0,0 +1,7 @@
#!/bin/bash -i
echo $PATH
target="armv7-unknown-linux-gnueabihf"
cargo build --target ${target}
sshpass -e q7s-cp.py ./target/${target}/debug/q7s-rs-crosscompile
+3
View File
@@ -0,0 +1,3 @@
fn main() {
println!("Hello, world!");
}