用Rust开发AVR单片机
环境准备
# FROM https://www.rust-lang.org/tools/install
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
# Enable it:
source $HOME/.cargo/env
# Add AVR toolchain:
git clone https://github.com/avr-rust/rust.git --recursive# Grab the avr-rust sources
git clone https://github.com/avr-rust/rust.git --recursive
# Create a directory to place built files in
mkdir build && cd build
# Generate Makefile using settings suitable for an experimental compiler
../rust/configure \
--enable-debug \
--disable-docs \
--enable-llvm-assertions \
--enable-debug-assertions \
--enable-optimize \
--enable-llvm-release-debuginfo \
--experimental-targets=AVR \
--prefix=/usr/local/avr-rust
# Build the compiler, install it to /usr/local/avr-rust
make
make install
最后更新于