1 # Maintainer: TryA <tryagainprod {at} gmail.com>
2 # Contributor: Judd <jvinet@zeroflux.org>
8 pkgdesc="A high-quality data compression program (32-bit)"
11 url="http://sources.redhat.com/bzip2"
12 depends=('lib32-glibc' $_pkgbasename)
13 makedepends=('gcc-multilib')
14 source=(http://www.bzip.org/$pkgver/bzip2-$pkgver.tar.gz)
15 md5sums=('00b516f4704d4a7cb50a1d97e6e8e15b')
18 cd ${srcdir}/${_pkgbasename}-${pkgver}
20 sed -i "s|CC=gcc|CC=gcc -m32|" Makefile
21 sed -i "s|CC=gcc|CC=gcc -m32|" Makefile-libbz2_so
23 # add large-file support
24 sed -e 's/^CFLAGS=\(.*\)$/CFLAGS=\1 \$(BIGFILES)/' -i ./Makefile-libbz2_so
26 # use our optimization
27 sed -i "s|-O2|${CFLAGS}|g" Makefile
28 sed -i "s|-O2|${CFLAGS}|g" Makefile-libbz2_so
30 make -f Makefile-libbz2_so
33 install -Dm755 libbz2.so.1.0.6 $pkgdir/usr/lib32/libbz2.so.1.0.6
34 ln -s libbz2.so.1.0.6 $pkgdir/usr/lib32/libbz2.so
35 ln -s libbz2.so.1.0.6 $pkgdir/usr/lib32/libbz2.so.1
36 ln -s libbz2.so.1.0.6 $pkgdir/usr/lib32/libbz2.so.1.0
38 install -Dm644 libbz2.a ${pkgdir}/usr/lib32/libbz2.a