From 1ab7e910fd19e2a201da1362f2850e93686d162a Mon Sep 17 00:00:00 2001 From: Tim Newsome Date: Fri, 19 Jan 2018 11:41:17 -0800 Subject: [PATCH] Make compilation command specify architecture. Fixes issue #180. Change-Id: Icf180ae87db92840930044f1aa3129466cf43fad --- src/flash/nor/fespi.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/flash/nor/fespi.c b/src/flash/nor/fespi.c index a12eb378f..83d533f30 100644 --- a/src/flash/nor/fespi.c +++ b/src/flash/nor/fespi.c @@ -465,8 +465,9 @@ static int slow_fespi_write_buffer(struct flash_bank *bank, * Here's the source for the algorithm. * You can turn it into the array below using: sed -n '/ALGO_START$/,/ALGO_END/ p' fespi.c | \ - riscv32-unknown-elf-gcc -x assembler-with-cpp - -nostdlib -nostartfiles -o tmp.o && \ - riscv32-unknown-elf-objcopy -O binary tmp.o algorithm.bin && \ + riscv64-unknown-elf-gcc -march=rv32i -mabi=ilp32 -x \ + assembler-with-cpp - -nostdlib -nostartfiles -o tmp.o && \ + riscv64-unknown-elf-objcopy -O binary tmp.o algorithm.bin && \ xxd -i algorithm.bin // ALGO_START