diff options
| author | Miquel Sabaté Solà <mikisabate@gmail.com> | 2024-09-03 16:03:26 +0200 |
|---|---|---|
| committer | Miquel Sabaté Solà <mikisabate@gmail.com> | 2024-12-05 16:02:49 +0100 |
| commit | 7233ca6dc0cd2513dccfcc521ecb9d1676fcc0b7 (patch) | |
| tree | bc6ed3ac1b74cfbd4a4535ece5f191fd10542448 /arch/riscv | |
| parent | 4f69fb67ee229c7b59ced5db64142b527d74ce7b (diff) | |
| download | farga-7233ca6dc0cd2513dccfcc521ecb9d1676fcc0b7.tar.gz farga-7233ca6dc0cd2513dccfcc521ecb9d1676fcc0b7.zip | |
Fix Makefile by allowing cross compilation
Since it was entirely developed on a real RISC-V board, I did not notice
issues with cross compilation.
Signed-off-by: Miquel Sabaté Solà <mikisabate@gmail.com>
Diffstat (limited to 'arch/riscv')
| -rw-r--r-- | arch/riscv/usr/Makefile | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/arch/riscv/usr/Makefile b/arch/riscv/usr/Makefile index 5f1ef3f..403fb14 100644 --- a/arch/riscv/usr/Makefile +++ b/arch/riscv/usr/Makefile @@ -1,7 +1,7 @@ -CC = $(CROSS_COMPILE)gcc -LD = $(CROSS_COMPILE)ld -CCFLAGS = -EXE = basics +CROSS_COMPILE ?= riscv64-suse-linux- +CC = $(CROSS_COMPILE)gcc +CCFLAGS = +EXE = basics DEBUG = ifneq ($(strip $(DEBUG)),) @@ -13,7 +13,7 @@ all: clean $(EXE) .PHONY: $(EXE) $(EXE): - gcc $(CCFLAGS) -o $(EXE) basics.c factorial.S string.S float.S + $(CC) $(CCFLAGS) -o $(EXE) basics.c factorial.S string.S float.S .PHONY: clean clean: |
