2018-12-23 18:25:04 +08:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
set -euxo pipefail
|
|
|
|
|
2019-12-28 18:11:12 +08:00
|
|
|
crate=riscv-rt
|
2018-12-23 18:25:04 +08:00
|
|
|
|
|
|
|
# remove existing blobs because otherwise this will append object files to the old blobs
|
|
|
|
rm -f bin/*.a
|
|
|
|
|
2019-12-28 18:11:12 +08:00
|
|
|
riscv64-unknown-elf-gcc -c -mabi=ilp32 -march=rv32imac asm.S -o bin/$crate.o
|
2019-06-26 04:11:58 +08:00
|
|
|
ar crs bin/riscv32imac-unknown-none-elf.a bin/$crate.o
|
|
|
|
ar crs bin/riscv32imc-unknown-none-elf.a bin/$crate.o
|
2019-03-01 22:00:36 +08:00
|
|
|
|
2019-12-28 18:11:12 +08:00
|
|
|
riscv64-unknown-elf-gcc -c -mabi=ilp32 -march=rv32i asm.S -DSKIP_MULTICORE -o bin/$crate.o
|
|
|
|
ar crs bin/riscv32i-unknown-none-elf.a bin/$crate.o
|
|
|
|
|
2019-03-01 22:00:36 +08:00
|
|
|
riscv64-unknown-elf-gcc -c -mabi=lp64 -march=rv64imac asm.S -o bin/$crate.o
|
|
|
|
ar crs bin/riscv64imac-unknown-none-elf.a bin/$crate.o
|
|
|
|
ar crs bin/riscv64gc-unknown-none-elf.a bin/$crate.o
|
2018-12-23 18:25:04 +08:00
|
|
|
|
|
|
|
rm bin/$crate.o
|