summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: cd732bec77100f9caad19bac21720302511b3c97 (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
42
43
44
45
46
47
# Maintainer: Austin Anderson <austin@angerson.org>
_xsnowver=1.42
_pkgname=xsnow-comp-patch
pkgname=$_pkgname-git
pkgver=16
pkgrel=1
pkgdesc="Compositor-friendly patch for Xsnow"
arch=('i686' 'x86_64')
url="https://github.com/protractorninja/$_pkgname"
license=('MIT' 'custom')
depends=('libxpm')
makedepends=('git' 'imake')
provides=('xsnow')
conflicts=('xsnow')
options=()
source=("git://github.com/protractorninja/$_pkgname.git" "http://janswaal.home.xs4all.nl/Xsnow/xsnow-$_xsnowver.tar.gz")
md5sums=('SKIP'
         '451d8fc0a2b5393b428faa496a556036')

pkgver() {
  cd "$srcdir/$_pkgname"
  git rev-list --count HEAD
}

prepare() {
  cd "$srcdir/xsnow-$_xsnowver"
  rm -f PATCH_LICENSE
  patch -p1 -i "$srcdir/xsnow-comp-patch/xsnow-comp.patch"
}

build() {
  cd "$srcdir/xsnow-$_xsnowver"

  sed -n '/Copyright$/,/ facilitate this./p' README > XSNOW_LICENSE
  xmkmf
  make depend
  make
}

package() {
  cd "$srcdir/xsnow-$_xsnowver"

  make DESTDIR="$pkgdir/" install
  make DESTDIR="$pkgdir/" install.man
  install -D -m644 XSNOW_LICENSE $pkgdir/usr/share/licenses/$pkgname/XSNOW_LICENSE
  install -D -m644 PATCH_LICENSE $pkgdir/usr/share/licenses/$pkgname/PATCH_LICENSE
}