aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas K. Hüttel <dilfridge@gentoo.org>2019-04-28 12:23:34 +0200
committerAndreas K. Hüttel <dilfridge@gentoo.org>2019-04-28 12:23:34 +0200
commitb42744dd8d41b9a471b0f99fe8d9e7cb8f806a9a (patch)
tree3f6b70e9557fdb84d97ec24edf152933da1a89d6
parentprofiles: We need overlay gcc (diff)
downloadriscv-b42744dd.tar.gz
riscv-b42744dd.tar.bz2
riscv-b42744dd.zip
eclass: filter -march in gcc build for riscv
Signed-off-by: Andreas K. Hüttel <dilfridge@gentoo.org>
-rw-r--r--eclass/toolchain.eclass5
1 files changed, 5 insertions, 0 deletions
diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass
index be94db8..ff66986 100644
--- a/eclass/toolchain.eclass
+++ b/eclass/toolchain.eclass
@@ -1513,6 +1513,11 @@ gcc_do_filter_flags() {
# dont want to funk ourselves
filter-flags '-mabi*' -m31 -m32 -m64
+ # on riscv, only specific combinations of march and mabi work... so we need
+ # to strip both and trust the compiler to do the right thing, otherwise
+ # multilib build fails
+ [[ $(tc-arch) == riscv* ]] && filter-flags '-march*'
+
filter-flags -frecord-gcc-switches # 490738
filter-flags -mno-rtm -mno-htm # 506202