summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorMaxr19982022-08-26 15:56:17 +0200
committerMaxr19982022-08-26 15:56:17 +0200
commit918954c623858b74f2014047e72d7e8b9ccf4c46 (patch)
tree0b11973122e2b8cf4c110df1e744e9676f4254d2 /PKGBUILD
parentf1994bc0f5694ec2549c6b2f066209c34fecf138 (diff)
downloadaur-918954c623858b74f2014047e72d7e8b9ccf4c46.tar.gz
Fix build on GCC 11+
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD5
1 files changed, 4 insertions, 1 deletions
diff --git a/PKGBUILD b/PKGBUILD
index fa4f957f28ce..bf24645f1a17 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
_pkgbase="rv8"
pkgname="rv8-git"
pkgver=2279.8342590
-pkgrel=1
+pkgrel=2
pkgdesc="RISC-V simulator for x86-64"
arch=('x86_64')
url="https://rv8.io/"
@@ -26,6 +26,9 @@ prepare() {
build() {
cd "$_pkgbase"
+ # https://stackoverflow.com/a/68149587/2475176
+ GCC_VER=$(g++ -dumpversion)
+ sed -i 's|\(CXXFLAGS =.*\)|\1\nCXXFLAGS += -include /usr/include/c++/'$GCC_VER'/limits|' Makefile
export RISCV="/usr"
make DEST_DIR="/usr" enable_harden=1
}