1 # Build recipe for tarlz.
3 # Copyright (c) 2019-2022 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 # Exit immediately on any error
24 # Define a category for the output of the package name
27 tarname=${program}-${version}.tar.lz
30 fetch=https://download-mirror.savannah.gnu.org/releases/lzip/tarlz/$tarname
32 homepage=https://lzip.nongnu.org/tarlz.html
36 Archiver with multimember lzip compression (version $version).
38 Tarlz is a combined implementation of the tar archiver and the lzip
39 compressor. By default tarlz creates, lists and extracts archives in a
40 simplified posix pax format compressed with lzip on a per file basis.
41 Each tar member is compressed in its own lzip member, as well as the
42 end-of-file blocks. This method adds an indexed lzip layer on top of
43 the tar archive, making it possible to decode the archive safely in
44 parallel. The resulting multimember tar.lz archive is fully backward
45 compatible with standard tar tools like GNU tar, which treat it like
46 any other tar.lz archive. Tarlz can append files to the end of such
50 # Limit package name to the program name
51 full_pkgname="${program}@${pkgcategory}"
53 # Source documentation
54 docs="AUTHORS COPYING ChangeLog NEWS README"
55 docsdir="${docdir}/${program}"
59 unpack "${tardir}/$tarname"
63 # Set sane permissions
64 chmod -R u+w,go-w,a+rX-s .
66 ./configure CPPFLAGS="$QICPPFLAGS" \
67 CXXFLAGS+="$QICXXFLAGS" LDFLAGS="$QILDFLAGS -static" \
71 --build="$(gcc -dumpmachine)"
74 make -j${jobs} DESTDIR="$destdir" install
76 # Compress info documents and manual page
78 rm -f "${destdir}/${infodir}/dir"; # Redundancy
80 "${destdir}/${infodir}/tarlz.info" \
81 "${destdir}/${mandir}/man1/tarlz.1"
84 mkdir -p "${destdir}/$docsdir"
85 cp -p $docs "${destdir}/$docsdir"