updated on Wed Jan 25 12:16:47 UTC 2012
[aur-mirror.git] / lm1100 / PKGBUILD
blobf33cf468b68edece7c06d24001ea09643c69939d
1 # $Id: PKGBUILD,v 1.2 2005/05/02 02:21:42 judd Exp $
2 # Contributor: Evgenij Vdovin <evdovin@pochta.ru>
3 pkgname=lm1100
4 pkgver=1.0.2a
5 pkgrel=1
6 pkgdesc="Lexmark 1000/1100 printer driver (page compiler)"
7 url="http://openprinting.org/show_printer.cgi?recnum=Lexmark-1000"
8 depends=('glibc')
9 makedepends=('perl')
10 source=(http://www.openprinting.org/download/printing/$pkgname/$pkgname.$pkgver.tar.gz \
11                                 http://www.openprinting.org/download/printing/$pkgname/${pkgname}maint.tar.gz \
12                                 http://www.openprinting.org/download/printing/$pkgname/$pkgname.$pkgver-fix-compile-gcc-3.4.patch.gz \
13                                 Lexmark-1000-lm1100.ppd gs-lm1100-0.1 \
14                                 lm1100maint-0.1 a4_page.patch)
15 md5sums=('2b96b75459f194eabd4321c55c90c797' '49c8a6a7af2e4b6cef68593bccd48496' \
16                                 'c0319924f7b0e9b335d48c1c099c67c6' \
17                                 '90de334aef817d313ccfa9e1391da452' '0e63bc9ea72c80354bf7916aff41f4fe' \
18                                 'cde562676f487bd7fd1b9241497e5f67' \
19                                 '69c0cc7716262320b24637b450bcbf43')
20 build() {
21   cd $startdir/src/$pkgname.$pkgver
22         # for gcc 3.1 or later
23         perl -p -i -e 's/friend Lexmark/friend class Lexmark/' *.h
24         # for gcc 3.4 or later
25         patch -N -i ../lm1100.1.0.2a-fix-compile-gcc-3.4.patch || return 1
26         # for gcc 4.1 or later
27         perl -p -i -e 's/\b[^\s:]+:://' *.h
28         # A4 page support
29         patch -Np1 -i ../a4_page.patch || return 1
30   make || return 1
31         mkdir -p $startdir/pkg/usr/{bin,share/lm1100}
32         install -D -m755  lm1100 $startdir/pkg/usr/bin
33         install -D -m755 byteutil.pl lexmark2ppm.pl ps-to-printer.fpi $startdir/pkg/usr/share/lm1100
34         install -D -m644 README ../Lexmark-1000-lm1100.ppd ../gs-lm1100-0.1 $startdir/pkg/usr/share/lm1100
35         cd $startdir/src/${pkgname}maint
36         mkdir -p $startdir/pkg/usr/share/lm1100maint
37         install -D -m755 ../lm1100maint-0.1 $startdir/pkg/usr/bin/lm1100maint
38         install -D -m644 lexmarkback lexmarkchange $startdir/pkg/usr/share/lm1100maint