mirror of
https://github.com/yann64/haikuports.git
synced 2026-03-19 01:46:00 +01:00
The configure patch was upstreamed. Add a small patch for gcc 2 to allow the use of vsnprintf.
90 lines
2.3 KiB
Bash
90 lines
2.3 KiB
Bash
SUMMARY="A massively spiffy yet delicately unobtrusive compression library"
|
|
DESCRIPTION="Zlib is designed to be a free, general-purpose, legally \
|
|
unencumbered -- that is, not covered by any patents -- lossless \
|
|
data-compression library for use on virtually any computer hardware and \
|
|
operating system. The zlib data format is itself portable across platforms.
|
|
|
|
Unlike the LZW compression method used in Unix compress(1) and in the GIF \
|
|
image format, the compression method currently used in zlib essentially never \
|
|
expands the data. (LZW can double or triple the file size in extreme cases.) \
|
|
zlib's memory footprint is also independent of the input data and can be \
|
|
reduced, if necessary, at some cost in compression."
|
|
HOMEPAGE="http://www.zlib.net/"
|
|
COPYRIGHT="1995-2026 Jean-loup Gailly and Mark Adler"
|
|
LICENSE="Zlib"
|
|
REVISION="1"
|
|
SOURCE_URI="
|
|
https://zlib.net/fossils/zlib-$portVersion.tar.gz
|
|
https://github.com/madler/zlib/releases/download/v$portVersion/zlib-$portVersion.tar.gz
|
|
"
|
|
CHECKSUM_SHA256="bb329a0a2cd0274d05519d61c667c062e06990d72e125ee2dfa8de64f0119d16"
|
|
PATCHES="zlib-$portVersion.patchset"
|
|
|
|
ARCHITECTURES="all"
|
|
SECONDARY_ARCHITECTURES="x86"
|
|
|
|
libVersion="$portVersion"
|
|
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
|
|
|
PROVIDES="
|
|
zlib$secondaryArchSuffix = $libVersionCompat
|
|
lib:libz$secondaryArchSuffix = $libVersionCompat
|
|
"
|
|
REQUIRES="
|
|
haiku$secondaryArchSuffix
|
|
"
|
|
|
|
SUMMARY_devel="The zlib development files"
|
|
PROVIDES_devel="
|
|
zlib${secondaryArchSuffix}_devel = $libVersionCompat
|
|
devel:libz$secondaryArchSuffix = $libVersionCompat
|
|
"
|
|
REQUIRES_devel="
|
|
zlib$secondaryArchSuffix == $portVersion base
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku${secondaryArchSuffix}_devel
|
|
"
|
|
BUILD_PREREQUIRES="
|
|
cmd:gcc$secondaryArchSuffix
|
|
cmd:ld$secondaryArchSuffix
|
|
cmd:make
|
|
cmd:sed
|
|
"
|
|
|
|
BUILD()
|
|
{
|
|
export mandir=$manDir # ./configure won't accept --mandir, but respects $mandir
|
|
export CFLAGS="-O2 -g -DNDEBUG" # similar to cmake's "RelWithDebugInfo" as used before.
|
|
|
|
./configure \
|
|
--prefix=$prefix \
|
|
--libdir=$libDir \
|
|
--includedir=$includeDir \
|
|
--sharedlibdir=$libDir
|
|
|
|
make $jobArgs
|
|
}
|
|
|
|
INSTALL()
|
|
{
|
|
make install
|
|
|
|
# remove static library
|
|
rm $libDir/libz.a
|
|
|
|
prepareInstalledDevelLib libz
|
|
fixPkgconfig
|
|
|
|
# devel package
|
|
packageEntries devel \
|
|
$developDir \
|
|
$documentationDir
|
|
}
|
|
|
|
TEST()
|
|
{
|
|
make test
|
|
}
|