description="Very high-quality data compression program." packager="CRUX System Team " maintainer="Lukc " url="http://www.bzip.org/" depends=() name=bzip2 version=1.0.6 release=1 source=(http://www.bzip.org/$version/$name-$version.tar.gz bzip2.patch) build () { local makeopts=( ${CTARGET:+CC=${CTARGET}-gcc} ${CTARGET:+AR=${CTARGET}-ar} ${CTARGET:+RANLIB=${CTARGET}-ranlib} ${CTARGET:+LD=${CTARGET}-ld} ) cd $name-$version; patch -Np1 -i $SRC/$name.patch; sed -i -e "/all:/ s| test||" Makefile; sed -i -e "s|/man|${mandir/$prefix}|g" Makefile; make ${makeopts[@]}; make PREFIX=$PKG$prefix MANDIR=$PKG$mandir install; make -f Makefile-libbz2_so ${makeopts}; make -f Makefile-libbz2_so PREFIX=$PKG$prefix MANDIR=$PKG$mandir install }