summaryrefslogtreecommitdiff
path: root/PKGBUILD
blob: 8063dc0bd39bee23d71d6f6d8e3f3a38edefdddd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# Maintainer: jc_gargma <jc_gargma@iserlohn-fortress.net>
# Maintainer (Arch): juergen <juergen@archlinux.org>
# Contributor (Arch): Manolis Tzanidakis, Petter Gundersen

# # I maintain this because:
# Arch version lacks additional optimization and hardening flags

pkgname=scummvm
pkgver=2.0.0
pkgrel=2.2
pkgdesc="A 'virtual machine' for several classic graphical point-and-click adventure games."
arch=('x86_64')
license=('GPL')
url="http://www.scummvm.org/"
depends=('libpng' 'libtheora' 'sdl2' 'fluidsynth' 'flac' 'faad2' 'libvorbis' 'libmad' 'freetype2'
         'libgl' 'glu' 'libjpeg-turbo' 'libmpeg2')
makedepends=('mesa')
source=("https://scummvm.org/frs/scummvm/${pkgver}/${pkgname}-${pkgver}.tar.xz")
sha512sums=('5f4c11145c5dfcc7ae95d5c0e5ac9e938912cc5060b9d5fdfcb699a745755b31412e44199e487ad388ca5e091afc3366f874610adb44d440f336e26d6cd4812c')

build() {
  cd "${srcdir}"/${pkgname}-${pkgver}
  # -flto=4 breaks compilation
  export CFLAGS="$CFLAGS -O3 -fPIE"
  export CXXFLAGS="$CXXFLAGS -O3 -fPIE"
  export LDFLAGS="$LDFLAGS,-pie"
  ./configure \
    --enable-all-engines \
    --enable-c++11 \
    --enable-release \
    --prefix=/usr
  make
}

package() {
  cd "${srcdir}"/${pkgname}-${pkgver}
  make DESTDIR=${pkgdir} install
  install -Dm644 dists/${pkgname}.desktop "${pkgdir}"/usr/share/applications/${pkgname}.desktop
}