We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
examples/codegen.rs
1 parent 10911d6 commit a9d9275Copy full SHA for a9d9275
Makefile
@@ -0,0 +1,20 @@
1
+# Makefile useful during development.
2
+# `make asm` compiles examples/codegen.rs to assembly.
3
+# The output can then be reviewed for correctness.
4
+
5
+NV?=nightly
6
+override FLAGS += -Z build-std=core -Z build-std-features=panic_immediate_abort --release
7
+MCU?=avr-atmega328p
8
+AVR_CPU_FREQUENCY_HZ?=16000000
9
+export AVR_CPU_FREQUENCY_HZ
10
11
+build:
12
+ cargo +$(NV) build $(FLAGS) --target=$(MCU).json -v
13
+ cargo +$(NV) build --example codegen $(FLAGS) --target=$(MCU).json -v
14
15
+asm:
16
+ cargo +$(NV) rustc --example codegen $(FLAGS) --target=$(MCU).json -- --emit asm
17
+ @echo target/$(MCU)/release/examples/*.s
18
19
+asmclean:
20
+ -rm target/*/release/deps/*.s
0 commit comments