forked from Github_Repos/cvw
17 lines
570 B
Makefile
17 lines
570 B
Makefile
TARGET = sumtest
|
||
|
||
$(TARGET).objdump: $(TARGET)
|
||
riscv64-unknown-elf-objdump -D $(TARGET) > $(TARGET).objdump
|
||
|
||
$(TARGET): $(TARGET).S sum.S
|
||
riscv64-unknown-elf-gcc -g -o $(TARGET) -march=rv64gc -mabi=lp64 -mcmodel=medany \
|
||
-nostartfiles -nostdlib -T../../link/link.ld $(TARGET).S sum.S
|
||
|
||
sim:
|
||
spike +signature=$(TARGET).signature.output +signature-granularity=8 $(TARGET)
|
||
diff --ignore-case $(TARGET).signature.output $(TARGET).reference_output || exit
|
||
echo "Signature matches! Success!"
|
||
|
||
clean:
|
||
rm -f $(TARGET) $(TARGET).objdump $(TARGET).signature.output
|
||
|