From 89a52cfe2173e64d03887f7404096197e935e7ef Mon Sep 17 00:00:00 2001 From: Gabriele Gristina Date: Sun, 6 Feb 2022 01:57:04 +0100 Subject: [PATCH] Fixed building error on Raspberry Pi --- docs/changes.txt | 1 + src/Makefile | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/docs/changes.txt b/docs/changes.txt index a914583f5..1e33d3a08 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -22,6 +22,7 @@ ## Bugs ## +- Fixed building error on Raspberry Pi - Fixed false negative on Unit Test in case of out-of-memory with grep in single mode - Fixed false negative on Unit Test with hash-type 25400 - Fixed functional error when nonce-error-corrections that were set on the command line in hash-mode 22000/22001 were not accepted diff --git a/src/Makefile b/src/Makefile index 4a5d419da..1b12013b5 100644 --- a/src/Makefile +++ b/src/Makefile @@ -254,6 +254,14 @@ endif endif endif +ifeq ($(UNAME),Linux) +IS_RPI := $(shell grep -q Raspberry /proc/cpuinfo && echo 1 || echo 0) + +ifeq ($(IS_RPI),1) +CFLAGS += -mcpu=cortex-a72 +endif +endif + CFLAGS += -pipe -Iinclude/ -IOpenCL/ # LZMA