summaryrefslogtreecommitdiffstats
path: root/main/zsnes/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'main/zsnes/APKBUILD')
-rw-r--r--main/zsnes/APKBUILD17
1 files changed, 12 insertions, 5 deletions
diff --git a/main/zsnes/APKBUILD b/main/zsnes/APKBUILD
index 6240d9c4d..6c4303e02 100644
--- a/main/zsnes/APKBUILD
+++ b/main/zsnes/APKBUILD
@@ -16,16 +16,23 @@ source="http://downloads.sourceforge.net/sourceforge/$pkgname/${pkgname}151src.t
zsnes-libpng15.patch
zsnes_icon.png"
-build() {
- cd "$srcdir"/${pkgname}_${pkgver%.*}_${pkgver#*.}
+_builddir="$srcdir/${pkgname}_${pkgver%.*}_${pkgver#*.}"
+
+prepare() {
+ cd "$_builddir"
+ update_config_sub || return 1
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
- cd "$srcdir"/${pkgname}_${pkgver%.*}_${pkgver#*.}/src
- aclocal && autoconf || return 1
+ cd "$_builddir"/src
+ aclocal && autoconf || return 1
+}
+
+build() {
+ cd "$_builddir"/src
export GCC_SPECS=hardenednopie.specs
LDFLAGS="$LDFLAGS -fno-PIE"
./configure \
@@ -42,7 +49,7 @@ build() {
}
package() {
- cd "$srcdir"/${pkgname}_${pkgver%.*}_${pkgver#*.}/src
+ cd "$_builddir"/src
make DESTDIR="$pkgdir" install
install -Dm644 "$srcdir"/zsnes.desktop \
"$pkgdir"/usr/share/applications/zsnes.desktop