0
0
Fork 0
haikuports/app-arch/pigz/pigz-2.6.recipe

72 lines
1.6 KiB
Bash

SUMMARY="A parallel implementation of gzip for multi-processor machines"
DESCRIPTION="
pigz, which stands for Parallel Implementation of GZip, is a fully functional \
replacement for gzip that exploits multiple processors and multiple cores to \
the hilt when compressing data.
pigz was written by Mark Adler, and uses the zlib and pthread libraries.
This version of pigz is written to be portable across Unix-style operating \
systems that provide the zlib and pthread libraries."
HOMEPAGE="http://www.zlib.net/pigz"
COPYRIGHT="2008-2013 Mark Adler"
LICENSE="Zlib"
REVISION="1"
SOURCE_URI="http://www.zlib.net/pigz/pigz-$portVersion.tar.gz"
CHECKSUM_SHA256="2eed7b0d7449d1d70903f2a62cd6005d262eb3a8c9e98687bc8cbb5809db2a7d"
ARCHITECTURES="all !x86_gcc2"
if [ "$targetArchitecture" = x86_gcc2 ]; then
SECONDARY_ARCHITECTURES="x86"
fi
# On x86_gcc2 we don't want to install the commands in bin/<arch>/, but in bin/.
commandBinDir=$binDir
if [ "$targetArchitecture" = x86_gcc2 ]; then
commandBinDir=$prefix/bin
fi
PROVIDES="
pigz$secondaryArchSuffix = $portVersion
cmd:pigz = $portVersion
cmd:unpigz = $portVersion
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libz$secondaryArchSuffix
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
devel:libz$secondaryArchSuffix
"
BUILD_PREREQUIRES="
cmd:gcc$secondaryArchSuffix
cmd:make
"
PATCH()
{
sed -i 's/-lm//g' Makefile
sed -i 's/-lpthread//g' Makefile
sed -i 's/ln -f/ln -sf/g' Makefile
}
BUILD()
{
make
}
INSTALL()
{
mkdir -p $commandBinDir
cp -af pigz unpigz $commandBinDir
mkdir -p $manDir/man1
cp -af pigz.1 $manDir/man1
}
TEST()
{
make test
}