From 9074b22ca60de20278329d7ec538fbc763b56308 Mon Sep 17 00:00:00 2001 From: Pratham Patel Date: Sat, 28 Oct 2023 13:32:19 +0530 Subject: [PATCH] Try fixing COPR builds COPR builds fail with the following error: ``` cc1: warning: unknown register name: x18 cc1: error: bad value ('armv8-a+crc') for '-march=' switch cc1: note: valid arguments to '-march=' switch are: nocona core2 nehalem corei7 westmere sandybridge corei7-avx ivybridge core-avx-i haswell core-avx2 broadwell skylake skylake-avx512 cannonlake icelake-client rocketlake icelake-server cascadelake tigerlake cooperlake sapphirerapids alderlake bonnell atom silvermont slm goldmont goldmont-plus tremont knl knm x86-64 x86-64-v2 x86-64-v3 x86-64-v4 eden-x2 nano nano-1000 nano-2000 nano-3000 nano-x2 eden-x4 nano-x4 k8 k8-sse3 opteron opteron-sse3 athlon64 athlon64-sse3 athlon-fx amdfam10 barcelona bdver1 bdver2 bdver3 bdver4 znver1 znver2 znver3 btver1 btver2 native make[1]: *** [scripts/Makefile.build:146: lib/asm-offsets.s] Error 1 ``` Try fixing it by exporting CROSS_COMPILE as 'aarch64-redhat-linux-' --- package.inc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/package.inc b/package.inc index 89ef178..be8bdc9 100644 --- a/package.inc +++ b/package.inc @@ -31,10 +31,12 @@ This package contains images for the %{board_name}. %prep %setup -q -n %{src_dir} +export CROSS_COMPILE=aarch64-redhat-linux- %{make} distclean %{make} %{board_defconfig} %build +export CROSS_COMPILE=aarch64-redhat-linux- %if "%{?rkbin_git_commit}" != "" pushd .. cp %{_sourcedir}/%{?rkbin_git_commit}.tar.gz .