mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-23 04:00:05 +02:00
lz5: new recipe.
This commit is contained in:
79
app-arch/lz5/lz5-2.0.recipe
Normal file
79
app-arch/lz5/lz5-2.0.recipe
Normal file
@@ -0,0 +1,79 @@
|
||||
SUMMARY="An efficient compressor with very fast decompression"
|
||||
DESCRIPTION="LZ5 is a lossless compression algorithm which contains 4 \
|
||||
compression methods:
|
||||
fastLZ4 : compression levels -10...-19 are designed to give better \
|
||||
decompression speed than LZ4 i.e. over 2000 MB/s
|
||||
LZ5v2 : compression levels -20...-29 are designed to give better ratio than \
|
||||
LZ4 keeping 75% decompression speed
|
||||
fastLZ4 + Huffman : compression levels -30...-39 add Huffman coding to fastLZ4
|
||||
LZ5v2 + Huffman : compression levels -40...-49 give the best ratio (comparable\
|
||||
to zlib and low levels of zstd/brotli) at decompression speed of 1000 MB/s."
|
||||
HOMEPAGE="https://github.com/inikep/lz5/"
|
||||
COPYRIGHT="2011-2016, Yann Collet
|
||||
2015-2016, Przemyslaw Skibinski"
|
||||
LICENSE="BSD (2-clause)"
|
||||
REVISION="1"
|
||||
SOURCE_URI="$HOMEPAGE/archive/v$portVersion.tar.gz"
|
||||
SOURCE_FILENAME="lz5-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="9d26494da492a9fd79b3baf93512a543f450b169bae01067354bd0179a5e3ede"
|
||||
PATCHES="lz5-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="?x86_gcc2 ?x86 x86_64"
|
||||
SECONDARY_ARCHITECTURES="?x86 ?x86_gcc2"
|
||||
|
||||
PROVIDES="
|
||||
lz5${secondaryArchSuffix} = $portVersion
|
||||
lib:liblz5${secondaryArchSuffix} = 2.0.0 compat >= 2
|
||||
"
|
||||
|
||||
if [ -z "$secondaryArchSuffix" ]; then
|
||||
PROVIDES="$PROVIDES
|
||||
cmd:lz5 = $portVersion
|
||||
cmd:lz5cat = $portVersion
|
||||
cmd:unlz5 = $portVersion
|
||||
"
|
||||
fi
|
||||
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix >= $haikuVersion
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
lz5${secondaryArchSuffix}_devel = $portVersion
|
||||
devel:liblz5$secondaryArchSuffix = 2.0.0 compat >= 2
|
||||
"
|
||||
REQUIRES_devel="
|
||||
lz5${secondaryArchSuffix} == $portVersion base
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel >= $haikuVersion
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:make
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
make -j1 all
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install LIBDIR=$libDir INCLUDEDIR=$includeDir \
|
||||
BINDIR=$binDir MANDIR=$manDir/man1
|
||||
|
||||
if [ -n "$secondaryArchSuffix" ]; then
|
||||
rm $binDir/lz5
|
||||
rm $binDir/lz5cat
|
||||
rm $binDir/unlz5
|
||||
fi
|
||||
|
||||
prepareInstalledDevelLib liblz5
|
||||
fixPkgconfig
|
||||
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
}
|
||||
95
app-arch/lz5/patches/lz5-2.0.patchset
Normal file
95
app-arch/lz5/patches/lz5-2.0.patchset
Normal file
@@ -0,0 +1,95 @@
|
||||
From 97fa9054367795d7c34319eb237fb21c9a9819ae Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Wed, 22 Feb 2017 22:02:08 +0100
|
||||
Subject: also install for Haiku.
|
||||
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index 72046f7..6b71f60 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -71,9 +71,9 @@ clean:
|
||||
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
-#make install is validated only for Linux, OSX, kFreeBSD, Hurd and
|
||||
+#make install is validated only for Linux, OSX, kFreeBSD, Hurd, Haiku and
|
||||
#FreeBSD targets
|
||||
-ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD))
|
||||
+ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD Haiku))
|
||||
HOST_OS = POSIX
|
||||
|
||||
install:
|
||||
diff --git a/lib/Makefile b/lib/Makefile
|
||||
index d3b1078..fe0771f 100644
|
||||
--- a/lib/Makefile
|
||||
+++ b/lib/Makefile
|
||||
@@ -101,9 +101,9 @@ clean:
|
||||
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
-#make install is validated only for Linux, OSX, kFreeBSD, Hurd and
|
||||
+#make install is validated only for Linux, OSX, kFreeBSD, Hurd, Haiku and
|
||||
#FreeBSD targets
|
||||
-ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD))
|
||||
+ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD Haiku))
|
||||
|
||||
liblz5.pc: liblz5.pc.in Makefile
|
||||
@echo creating pkgconfig
|
||||
diff --git a/programs/Makefile b/programs/Makefile
|
||||
index 1f51d25..efdd40a 100644
|
||||
--- a/programs/Makefile
|
||||
+++ b/programs/Makefile
|
||||
@@ -98,9 +98,9 @@ clean:
|
||||
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
-#make install is validated only for Linux, OSX, kFreeBSD, Hurd and
|
||||
+#make install is validated only for Linux, OSX, kFreeBSD, Hurd, Haiku and
|
||||
#FreeBSD targets
|
||||
-ifneq (,$(filter Linux Darwin GNU/kFreeBSD GNU FreeBSD MSYS%, $(shell uname)))
|
||||
+ifneq (,$(filter Linux Darwin GNU/kFreeBSD GNU FreeBSD Haiku MSYS%, $(shell uname)))
|
||||
|
||||
install: lz5$(EXT)
|
||||
@echo Installing binaries
|
||||
diff --git a/tests/Makefile b/tests/Makefile
|
||||
index 3977a64..53f5790 100644
|
||||
--- a/tests/Makefile
|
||||
+++ b/tests/Makefile
|
||||
@@ -128,9 +128,9 @@ versionsTest:
|
||||
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
-#make install is validated only for Linux, OSX, kFreeBSD, Hurd and
|
||||
+#make install is validated only for Linux, OSX, kFreeBSD, Hurd, Haiku and
|
||||
#FreeBSD targets
|
||||
-ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD))
|
||||
+ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD Haiku))
|
||||
|
||||
test: test-lz5 test-lz5c test-frametest test-fullbench test-fuzzer
|
||||
|
||||
--
|
||||
2.10.2
|
||||
|
||||
|
||||
From 7cb987998323b94fc1d5c64c99e83a6028d2ea4d Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Wed, 22 Feb 2017 22:12:30 +0100
|
||||
Subject: include string.h
|
||||
|
||||
|
||||
diff --git a/programs/util.h b/programs/util.h
|
||||
index 2b09b11..7216628 100644
|
||||
--- a/programs/util.h
|
||||
+++ b/programs/util.h
|
||||
@@ -33,6 +33,7 @@ extern "C" {
|
||||
#include <stdlib.h> /* malloc */
|
||||
#include <stddef.h> /* size_t, ptrdiff_t */
|
||||
#include <stdio.h> /* fprintf */
|
||||
+#include <string.h> /* strlen, strncpy */
|
||||
#include <sys/types.h> /* stat, utime */
|
||||
#include <sys/stat.h> /* stat */
|
||||
#if defined(_MSC_VER)
|
||||
--
|
||||
2.10.2
|
||||
|
||||
Reference in New Issue
Block a user