mirror of
git://git.code.sf.net/p/openocd/code
synced 2025-07-20 04:54:12 +10:00
Valgrind and Clang Static Analyzer have no complaints about this change. Change-Id: I7757615ec52448372bdc57729cdf97c7016d97e8 Signed-off-by: Tim Newsome <tim@sifive.com> Reviewed-on: http://openocd.zylin.com/4656 Tested-by: jenkins Reviewed-by: Philipp Guehring <pg@futureware.at> Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
29 lines
472 B
Makefile
29 lines
472 B
Makefile
BIN2C = ../../../../src/helper/bin2char.sh
|
|
|
|
CROSS_COMPILE ?= riscv64-unknown-elf-
|
|
|
|
CC=$(CROSS_COMPILE)gcc
|
|
OBJCOPY=$(CROSS_COMPILE)objcopy
|
|
OBJDUMP=$(CROSS_COMPILE)objdump
|
|
|
|
CFLAGS = -march=rv32i -mabi=ilp32 -x assembler-with-cpp -nostdlib -nostartfiles
|
|
|
|
all: fespi.inc
|
|
|
|
.PHONY: clean
|
|
|
|
%.elf: %.S
|
|
$(CC) $(CFLAGS) $< -o $@
|
|
|
|
%.lst: %.elf
|
|
$(OBJDUMP) -S $< > $@
|
|
|
|
%.bin: %.elf
|
|
$(OBJCOPY) -Obinary $< $@
|
|
|
|
%.inc: %.bin
|
|
$(BIN2C) < $< > $@
|
|
|
|
clean:
|
|
-rm -f *.elf *.lst *.bin *.inc
|