recipes: compressors/plzip: upgraded to version 1.8
[dragora.git] / recipes / compressors / plzip / recipe
blobfaef641e7abc66918026b93da73def5dc5baa5c1
1 # Build recipe for plzip.
3 # Copyright (c) 2017-2019 Matias Fonzo, <selk@dragora.org>.
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at
9 #    http://www.apache.org/licenses/LICENSE-2.0
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
17 program=plzip
18 version=1.8
19 release=1
21 # Set 'outdir' for a nice and well-organized output directory
22 outdir="${outdir}/${arch}/compressors"
24 tarname=${program}-${version}.tar.lz
26 # Remote source(s)
27 fetch=http://download.savannah.gnu.org/releases/lzip/plzip/$tarname
29 homepage=http://lzip.nongnu.org/plzip.html
30 license=GPLv2+
32 description="
33 A massively parallel lossless data compressor.
35 Plzip is a massively parallel (multi-threaded) lossless data compressor
36 based on the lzlib compression library, with a user interface similar
37 to the one of lzip, bzip2 or gzip.
39 Plzip can compress/decompress large files on multiprocessor machines
40 much faster than lzip, at the cost of a slightly reduced compression
41 ratio (0.4 to 2 percent larger compressed files).  Note that the number
42 of usable threads is limited by file size; on files larger than a
43 few GB plzip can use hundreds of processors, but on files of only a
44 few MB plzip is no faster than lzip.
46 For more information, visit: $homepage
49 # Source documentation
50 docs="AUTHORS COPYING ChangeLog NEWS README"
51 docsdir="${docdir}/${program}-${version}"
53 build()
55     set -e
57     unpack "${tardir}/$tarname"
59     cd "$srcdir"
61     # Set sane permissions
62     chmod -R u+w,go-w,a+rX-s .
64     ./configure CXXFLAGS="$QICXXFLAGS -Wall -W" \
65     LDFLAGS="$QILDFLAGS" \
66      $configure_args \
67      --infodir=$infodir \
68      --mandir=$mandir \
69      --build="$(cc -dumpmachine)"
71     make -j${jobs}
72     make -j${jobs} DESTDIR="$destdir" install
74     # Compress info documents and manual page
76     rm -f "${destdir}/${infodir}/dir";  # Redundancy
77     lzip -9 \
78      "${destdir}/${infodir}/plzip.info" \
79      "${destdir}/${mandir}/man1/plzip.1"
81     # Copy documentation
82     mkdir -p "${destdir}${docsdir}"
83     cp -p $docs "${destdir}${docsdir}"