From b89666bb773f751b3ec59b440e85d09dc5e25773 Mon Sep 17 00:00:00 2001 From: jc_gargma Date: Thu, 26 Sep 2019 18:37:47 -0700 Subject: Add hardened and optimization flags --- PKGBUILD | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/PKGBUILD b/PKGBUILD index 7842a1b..250694a 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -4,10 +4,11 @@ # # I maintain this because: # AUR version doesn't cd to the correct subdirectory +# Arch version lacks additional optimization and hardening flags pkgname=residualvm pkgver=0.3.1 -pkgrel=4 +pkgrel=4.2 pkgdesc="A cross-platform 3D game interpreter for LucasArts LUA-based 3D adventures" arch=('x86_64') license=('LGPL') @@ -20,6 +21,10 @@ sha256sums=('515b02129dd374bc9c0b732ddeaaaa3a342cc25ea0ea3c4ccf19141b5d362e1d') build() { cd "${srcdir}/$pkgname-$pkgver" + # -flto=4 breaks compilation + export CFLAGS="$CFLAGS -O3 -fPIE" + export CXXFLAGS="$CXXFLAGS -O3 -fPIE" + export LDFLAGS="$LDFLAGS,-pie" ./configure --disable-debug \ --enable-release \ --prefix=/usr -- cgit v1.2.1