summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: f8b36c8f68ab230480c76847b899bafaaa943133 (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
40
41
# Maintainer: Dimitris Kiziridis <ragouel at outlook dot com>

pkgname=('rednukem-git')
pkgver=r256.19f24f3
pkgrel=3
pkgdesc="Redneck Rampage and Duke Nukem 3D port based on EDuke32"
arch=('i686' 'x86_64')
url="https://github.com/nukeykt/NRedneck/"
license=('GPL' 'custom: BUILD')
depends=('sdl2_mixer' 'libgl' 'libvpx' 'flac' 'gtk2')
makedepends=('mesa' 'glu')
makedepends_i686=('nasm')
install='rednukem.install'
source=("git+$url")
sha256sums=('SKIP')

pkgver() {
  cd "$srcdir/NRedneck"
  ( 
    set -o pipefail
    git describe --long 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
    printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
  )
}

build() {
  cd "$srcdir/NRedneck"
  # add cxxflags, set revision
  make PACKAGE_REPOSITORY=1 #PRETTY_OUTPUT=0
}

package() {
  cd "$srcdir/NRedneck"
  # install binaries, buildlicense, icon and desktop files
  install -d "$pkgdir/usr/bin"
  install -m 755 rednukem "$pkgdir/usr/bin/"
  install -Dm 644 "package/common/buildlic.txt" "$pkgdir/usr/share/licenses/$pkgname/buildlic.txt"
  install -Dm 644 "../../rednukem.png" "$pkgdir/usr/share/pixmaps/rednukem.png"
  install -Dm 644 "../../rednukem.desktop" "$pkgdir/usr/share/applications/rednukem.desktop"
}
# vim:set ts=2 sw=2 et: