summaryrefslogtreecommitdiff
path: root/assembly/landingpad-test/Makefile
diff options
context:
space:
mode:
authorcheapie <cheapiephp@gmail.com>2026-06-23 18:54:53 -0500
committercheapie <cheapiephp@gmail.com>2026-06-23 18:54:53 -0500
commit3acb10122050d710845a7c35e84423cc1aae5632 (patch)
tree2eadd0c8514b7fd046621b26f79db156349c22e9 /assembly/landingpad-test/Makefile
parent41a6282fb32a3a7dbeca64191ddd804585bca5f4 (diff)
downloadrvcontroller-3acb10122050d710845a7c35e84423cc1aae5632.tar
rvcontroller-3acb10122050d710845a7c35e84423cc1aae5632.tar.gz
rvcontroller-3acb10122050d710845a7c35e84423cc1aae5632.tar.bz2
rvcontroller-3acb10122050d710845a7c35e84423cc1aae5632.tar.xz
rvcontroller-3acb10122050d710845a7c35e84423cc1aae5632.zip
Add Zicfilp extension and some CSR improvements
Diffstat (limited to 'assembly/landingpad-test/Makefile')
-rw-r--r--assembly/landingpad-test/Makefile24
1 files changed, 24 insertions, 0 deletions
diff --git a/assembly/landingpad-test/Makefile b/assembly/landingpad-test/Makefile
new file mode 100644
index 0000000..139d2c3
--- /dev/null
+++ b/assembly/landingpad-test/Makefile
@@ -0,0 +1,24 @@
+MARCH ?= rv32imacbzicntr_zicond_zicsr_zifencei_zihintpause_zilsd_zclsd_zabha_zacas_zawrs_zbkb_zbkx_zcb_zcmp_zcmt_zicfilp
+
+.PHONY: all dump load clean
+
+all: landingpad-test.hex
+
+landingpad-test.o: landingpad-test.S
+ riscv32-none-elf-as -I../rvcontroller-libraries -march=${MARCH} -o landingpad-test.o landingpad-test.S
+
+landingpad-test.elf: landingpad-test.o
+ riscv32-none-elf-ld -T rvcontroller.ld --no-warn-rwx-segments -o landingpad-test.elf landingpad-test.o
+
+dump: landingpad-test.elf
+ riscv32-none-elf-objdump -d landingpad-test.elf
+
+landingpad-test.hex: landingpad-test.elf
+ riscv32-none-elf-objcopy -O ihex landingpad-test.elf landingpad-test.hex
+
+load: landingpad-test.hex
+ bash -c "wl-copy < landingpad-test.hex"
+
+clean:
+ rm -f landingpad-test.hex landingpad-test.elf landingpad-test.o
+