diff options
author | Tim Schumacher | 2021-08-14 00:13:44 +0200 |
---|---|---|
committer | Tim Schumacher | 2021-08-14 00:13:44 +0200 |
commit | 56b523f432802826305e0ff32d60557d006f5361 (patch) | |
tree | b25d16d74999cabdfa94d7b7445a62e237ddbcd1 | |
parent | bcb9b20a2ded2688017ddf551081e328006880a2 (diff) | |
download | aur-56b523f432802826305e0ff32d60557d006f5361.tar.gz |
Disable LTO and increase expression nesting limit for clang
-rw-r--r-- | .SRCINFO | 3 | ||||
-rw-r--r-- | PKGBUILD | 13 |
2 files changed, 13 insertions, 3 deletions
@@ -1,6 +1,6 @@ pkgbase = citra-git pkgdesc = An experimental open-source Nintendo 3DS emulator/debugger - pkgver = r8793.d88d22080 + pkgver = r9037.c40871f12 pkgrel = 1 url = https://github.com/citra-emu/citra/ arch = i686 @@ -29,4 +29,3 @@ pkgname = citra-qt-git depends = desktop-file-utils optdepends = libxkbcommon-x11: for X11 support optdepends = qt5-wayland: for Wayland support - @@ -5,7 +5,7 @@ _pkgbase='citra' pkgbase="$_pkgbase-git" pkgname=("$_pkgbase-git" "$_pkgbase-qt-git") -pkgver=r8793.d88d22080 +pkgver=r9037.c40871f12 pkgrel=1 pkgdesc="An experimental open-source Nintendo 3DS emulator/debugger" arch=('i686' 'x86_64') @@ -16,6 +16,12 @@ makedepends=('git' 'cmake' 'sdl2' 'qt5-base' 'shared-mime-info' 'desktop-file-ut source=("$_pkgbase::git+https://github.com/citra-emu/citra") md5sums=('SKIP') +# Clang generates weird object files when LTO is enabled, breaking static libraries (.a). +# Force-disable LTO if we are using clang. +if [ "$CXX" = "clang++" ]; then + options=('!lto') +fi + pkgver() { cd "$srcdir/$_pkgbase" echo "r$(git rev-list --count HEAD).$(git rev-parse --short HEAD)" @@ -35,6 +41,11 @@ build() { # Fix for an issue some users are facing when compiling with GCC CXXFLAGS+=" -DFMT_USE_USER_DEFINED_LITERALS=0" + # Bump the expression nesting limit for clang + if [ "$CXX" = "clang++" ]; then + CXXFLAGS+=" -fbracket-depth=649" + fi + cmake .. \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_BUILD_TYPE=Release \ |