summaryrefslogtreecommitdiff
path: root/extra/fortune-mod/PKGBUILD
blob: a88f7bdb65896a90388a2fc8f23ac30edbfbc4da (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
# $Id: PKGBUILD 128484 2011-06-24 04:37:24Z eric $
# Maintainer: Kevin Piche <kevin@archlinux.org>
# Contributor: Dale Blount <archlinux@dale.us>

pkgname=fortune-mod
pkgver=1.99.1
pkgrel=5
pkgdesc="The Fortune Cookie Program from BSD games"
arch=('i686' 'x86_64' 'mips64el')
url="http://www.redellipse.net/code/fortune"
license=('BSD')
depends=('recode')
source=(ftp://ftp.archlinux.org/other/fortune-mod/$pkgname-$pkgver.tar.gz LICENSE 01_all_fortune_all-fix.patch)
md5sums=('f208805b3b712e32997d7667e0ec52d8'
         '0217481ae93971296cfb7872157cabb7'
         'e85b073f16dc6f0e8f0ed90044797aa3')

build() {
  cd "$srcdir/$pkgname-$pkgver"
  patch -p0 < ../01_all_fortune_all-fix.patch
  make REGEXDEFS='-DHAVE_REGEX_H -DPOSIX_REGEX -DHAVE_STDBOOL'  \
       COOKIEDIR=/usr/share/fortune  \
       LOCALDIR=/usr/local/share/fortune all fortune/fortune.man
}

package() {
  cd "$srcdir/$pkgname-$pkgver"
  make FORTDIR="$pkgdir"/usr/bin \
       COOKIEDIR="$pkgdir"/usr/share/fortune \
       BINDIR="$pkgdir"/usr/sbin \
       BINMANDIR="$pkgdir"/usr/share/man/man1 \
       FORTMANDIR="$pkgdir"/usr/share/man/man6 install
  rm "$pkgdir"/usr/share/fortune/*.u8
  rm "$pkgdir"/usr/share/fortune/off/*.u8
  install -D -m644 ../LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}