From: rishi Date: Mon, 19 Mar 2018 16:02:53 +0000 (-0400) Subject: Update Makefile to allow for RISCV_PREFIX to be set by the configure --target X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=d25e3867dbf01cb9f931704b5e844c63da6e4102;p=riscv-tests.git Update Makefile to allow for RISCV_PREFIX to be set by the configure --target --- diff --git a/Makefile.in b/Makefile.in index c073655..ea71c6b 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1,6 +1,12 @@ prefix := @prefix@ abs_top_src_dir := @abs_top_srcdir@ XLEN := @XLEN@ +target_alias := @target_alias@ +ifeq ($(target_alias),) +RISCV_PREFIX_VAR := +else +RISCV_PREFIX_VAR := RISCV_PREFIX=@target_alias@- +endif instbasedir := $(DESTDIR)$(prefix) bmarkdir := $(abs_top_src_dir)/benchmarks isa_src_dir := $(abs_top_src_dir)/isa @@ -16,11 +22,11 @@ install: all benchmarks: mkdir -p benchmarks - $(MAKE) -C benchmarks -f $(bmarkdir)/Makefile src_dir=$(bmarkdir) XLEN=$(XLEN) + $(MAKE) -C benchmarks -f $(bmarkdir)/Makefile src_dir=$(bmarkdir) XLEN=$(XLEN) $(RISCV_PREFIX_VAR) isa: mkdir -p isa - $(MAKE) -C isa -f $(isa_src_dir)/Makefile src_dir=$(isa_src_dir) XLEN=$(XLEN) + $(MAKE) -C isa -f $(isa_src_dir)/Makefile src_dir=$(isa_src_dir) XLEN=$(XLEN) $(RISCV_PREFIX_VAR) debug-check: mkdir -p debug