我最近买了一个树莓皮2,我想在上面运行一个Rust 程序.
有关于如何在Raspberry PI 2上交叉编译Rust程序的指南/说明吗?我听说过在RPi或Arduino上运行 rust 迹,虽然不是最近.
我想要一个在Raspberry Pi 2上运行的Hello World
个等效Rust程序.它不一定是一个字面上的Hello World程序,只是一个类似的低复杂度程序.
我最近买了一个树莓皮2,我想在上面运行一个Rust 程序.
有关于如何在Raspberry PI 2上交叉编译Rust程序的指南/说明吗?我听说过在RPi或Arduino上运行 rust 迹,虽然不是最近.
我想要一个在Raspberry Pi 2上运行的Hello World
个等效Rust程序.它不一定是一个字面上的Hello World程序,只是一个类似的低复杂度程序.
我们现在有rustup个.
$ rustup target add arm-unknown-linux-gnueabihf
$ sudo apt-get install gcc-arm-linux-gnueabihf
$ echo '[target.arm-unknown-linux-gnueabihf]' >> ~/.cargo/config
$ echo 'linker = "arm-linux-gnueabihf-gcc"' >> ~/.cargo/config
$ cd <project dir>
$ cargo build --target=arm-unknown-linux-gnueabihf