summaryrefslogtreecommitdiff
path: root/community/beye/PKGBUILD
blob: 9272f8eb6d0e39784154c1caa3ee5c66d9d14a4c (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
# $Id: PKGBUILD 6531 2009-12-15 08:58:26Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Sergej Pupykin <pupykin.s+arch@gmail.com>

pkgname=beye
pkgver=6.1.0
_lver=610
pkgrel=1
pkgdesc="Binary viewer"
arch=(i686 x86_64 'mips64el')
license=('GPL')
depends=(slang gpm)
replaces=(biew)
url="http://beye.sourceforge.net/"
options=(zipman)
source=(http://downloads.sourceforge.net/project/beye/biew/$pkgver/biew-${_lver}-src.tar.bz2)
md5sums=('1b6477defaa61b8ca0f2ae1254978e94')

build() {
  cd $startdir/src/biew-${_lver}

  CFLAGS="$CFLAGS -mmmx -msse" ./configure --prefix=/usr

  make || return 1

  sed -i "s|PREFIX=/usr|PREFIX=$startdir/pkg/usr|" config.mak
  sed -i "s|DATADIR=/usr/share/biew|DATADIR=$startdir/pkg/usr/share/biew|" config.mak
  sed -i "s|LIBDIR=/usr/lib/biew|LIBDIR=$startdir/pkg/usr/lib/biew|" config.mak

  patch makefile <<EOF
266,267c266,266
< 	\$(INSTALL) -D -c -m 644 bin_rc/xlt/* \$(DATADIR)/xlt
< 	\$(INSTALL) -D -c -m 644 bin_rc/xlt/russian/* \$(DATADIR)/xlt/russian
---
> 	cp -r bin_rc/xlt/* \${DATADIR}/xlt
EOF

  make prefix=$startdir/pkg/usr install || return 1

  mv $pkgdir/usr/man $pkgdir/usr/share/
}