gnu: python-publicsuffix2: Update to 2.20160818.
[jackhill/guix/guix.git] / gnu / packages / compression.scm
CommitLineData
233e7676 1;;; GNU Guix --- Functional package management for GNU
b2859a4f 2;;; Copyright © 2012, 2013, 2014, 2015, 2017 Ludovic Courtès <ludo@gnu.org>
b357faac 3;;; Copyright © 2013 Andreas Enge <andreas@enge.fr>
0a5c3087 4;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
27f76fe6 5;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
69d9792a 6;;; Copyright © 2015, 2016 Eric Bavier <bavier@member.fsf.org>
669b7b83 7;;; Copyright © 2015, 2016 Ricardo Wurmus <rekado@elephly.net>
82aa2a28 8;;; Copyright © 2015 Leo Famulari <leo@famulari.name>
820dc3f5 9;;; Copyright © 2015 Jeff Mickey <j@codemac.net>
effd7198 10;;; Copyright © 2015, 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
23f3cbb8 11;;; Copyright © 2016 Ben Woodcroft <donttrustben@gmail.com>
3fd4b90d 12;;; Copyright © 2016 Danny Milosavljevic <dannym@scratchpost.org>
36df995c 13;;; Copyright © 2016, 2017 Tobias Geerinckx-Rice <me@tobias.gr>
e4c2136d 14;;; Copyright © 2016 David Craven <david@craven.ch>
adbd7faf 15;;; Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
618089f9 16;;; Copyright © 2016 Marius Bakke <mbakke@fastmail.com>
1ae60db8 17;;; Copyright © 2017 ng0 <contact.ng0@cryptolab.net>
a268f085 18;;;
233e7676 19;;; This file is part of GNU Guix.
a268f085 20;;;
233e7676 21;;; GNU Guix is free software; you can redistribute it and/or modify it
a268f085
LC
22;;; under the terms of the GNU General Public License as published by
23;;; the Free Software Foundation; either version 3 of the License, or (at
24;;; your option) any later version.
25;;;
233e7676 26;;; GNU Guix is distributed in the hope that it will be useful, but
a268f085
LC
27;;; WITHOUT ANY WARRANTY; without even the implied warranty of
28;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29;;; GNU General Public License for more details.
30;;;
31;;; You should have received a copy of the GNU General Public License
233e7676 32;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
a268f085 33
1ffa7090 34(define-module (gnu packages compression)
b5b73a82 35 #:use-module ((guix licenses) #:prefix license:)
21b2ec4d 36 #:use-module (guix utils)
a268f085 37 #:use-module (guix packages)
87f5d366 38 #:use-module (guix download)
646898b3 39 #:use-module (guix git-download)
b357faac 40 #:use-module (guix build-system gnu)
73f542c3 41 #:use-module (guix build-system perl)
1ae60db8 42 #:use-module (guix build-system python)
e99dd67a 43 #:use-module (gnu packages)
389eb3fa 44 #:use-module (gnu packages assembly)
69d9792a 45 #:use-module (gnu packages autotools)
23f3cbb8 46 #:use-module (gnu packages backup)
73f542c3 47 #:use-module (gnu packages base)
646898b3 48 #:use-module (gnu packages perl)
23f3cbb8 49 #:use-module (gnu packages pkg-config)
1ae60db8 50 #:use-module (gnu packages python)
82aa2a28 51 #:use-module (gnu packages valgrind)
36df995c 52 #:use-module (ice-9 match)
646898b3 53 #:use-module ((srfi srfi-1) #:select (last)))
a268f085 54
6a92093d
LC
55(define-public zlib
56 (package
57 (name "zlib")
209e09fa 58 (version "1.2.8")
6a92093d
LC
59 (source
60 (origin
87f5d366 61 (method url-fetch)
a67f97fe
CR
62 (uri (list (string-append "http://zlib.net/zlib-"
63 version ".tar.gz")
b2859a4f
LC
64 (string-append "mirror://sourceforge/libpng/zlib/"
65 version "/zlib-" version ".tar.gz")))
6a92093d
LC
66 (sha256
67 (base32
209e09fa 68 "039agw5rqvqny92cpkrfn243x2gd4xn13hs3xi6isk55d2vqqr9n"))))
6a92093d
LC
69 (build-system gnu-build-system)
70 (arguments
71 `(#:phases (alist-replace
72 'configure
73 (lambda* (#:key outputs #:allow-other-keys)
e67253db 74 ;; Zlib's home-made `configure' fails when passed
6a92093d
LC
75 ;; extra flags like `--enable-fast-install', so we need to
76 ;; invoke it with just what it understand.
77 (let ((out (assoc-ref outputs "out")))
e67253db
JD
78 ;; 'configure' doesn't understand '--host'.
79 ,@(if (%current-target-system)
80 `((setenv "CHOST" ,(%current-target-system)))
81 '())
82 (zero?
83 (system* "./configure"
84 (string-append "--prefix=" out)))))
6a92093d
LC
85 %standard-phases)))
86 (home-page "http://zlib.net/")
35b9e423 87 (synopsis "Compression library")
6a92093d
LC
88 (description
89 "zlib is designed to be a free, general-purpose, legally unencumbered --
90that is, not covered by any patents -- lossless data-compression library for
91use on virtually any computer hardware and operating system. The zlib data
35b9e423 92format is itself portable across platforms. Unlike the LZW compression method
6a92093d
LC
93used in Unix compress(1) and in the GIF image format, the compression method
94currently used in zlib essentially never expands the data. (LZW can double or
95triple the file size in extreme cases.) zlib's memory footprint is also
96independent of the input data and can be reduced, if necessary, at some cost
97in compression.")
4a44e743 98 (license license:zlib)))
6a92093d 99
8298df96
MB
100(define-public minizip
101 (package
102 (name "minizip")
103 (version (package-version zlib))
104 (source (package-source zlib))
105 (build-system gnu-build-system)
106 (arguments
107 `(#:phases
108 (modify-phases %standard-phases
109 (add-after 'unpack 'enter-source
110 (lambda _ (chdir "contrib/minizip") #t))
111 (add-before 'configure 'autoreconf
112 (lambda _
113 (zero? (system* "autoreconf" "-vif")))))))
114 (native-inputs
115 `(("autoconf" ,autoconf)
116 ("automake" ,automake)
117 ("libtool" ,libtool)))
118 (propagated-inputs `(("zlib" ,zlib)))
119 (home-page (package-home-page zlib))
120 (synopsis "Zip Compression library")
121 (description
122 "Minizip is a minimalistic library that supports compressing,
123extracting and viewing ZIP archives. This version is extracted from
124the @code{zlib} source.")
125 (license (package-license zlib))))
126
ee97be9f
RW
127(define-public fastjar
128 (package
129 (name "fastjar")
130 (version "0.98")
131 (source (origin
132 (method url-fetch)
133 (uri (string-append "mirror://savannah/fastjar/fastjar-"
134 version ".tar.gz"))
135 (sha256
136 (base32
137 "0iginbz2m15hcsa3x4y7v3mhk54gr1r7m3ghx0pg4n46vv2snmpi"))))
138 (build-system gnu-build-system)
139 (inputs `(("zlib" ,zlib)))
140 (home-page "http://savannah.nongnu.org/projects/fastjar")
141 (synopsis "Replacement for Sun's 'jar' utility")
142 (description
143 "FastJar is an attempt to create a much faster replacement for Sun's 'jar'
144utility. Instead of being written in Java, FastJar is written in C.")
145 (license license:gpl2+)))
146
58593975
RW
147(define-public libtar
148 (package
149 (name "libtar")
89d80159 150 (version "1.2.20")
58593975
RW
151 (source (origin
152 (method url-fetch)
89d80159
EF
153 (uri (list
154 (string-append
155 "ftp://ftp.feep.net/pub/software/libtar/libtar-"
156 version ".tar.gz")
157 (string-append
158 "mirror://debian/pool/main/libt/libtar/libtar_"
159 version ".orig.tar.gz")))
58593975
RW
160 (sha256
161 (base32
e99dd67a
EF
162 "02cihzl77ia0dcz7z2cga2412vyhhs5pa2355q4wpwbyga2lrwjh"))
163 (patches (search-patches "libtar-CVE-2013-4420.patch"))))
58593975 164 (build-system gnu-build-system)
89d80159
EF
165 (arguments
166 `(#:tests? #f ;no "check" target
167 #:phases
168 (modify-phases %standard-phases
169 (add-after 'unpack 'autoconf
170 (lambda _ (zero? (system* "sh" "autoreconf" "-vfi")))))))
171 (native-inputs
172 `(("autoconf" ,autoconf)
173 ("automake" ,automake)
174 ("libtool" ,libtool)))
175 (inputs
176 `(("zlib" ,zlib)))
58593975
RW
177 (synopsis "C library for manipulating POSIX tar files")
178 (description
179 "libtar is a C library for manipulating POSIX tar files. It handles
180adding and extracting files to/from a tar archive.")
89d80159 181 (home-page "https://repo.or.cz/libtar.git")
58593975
RW
182 (license license:bsd-3)))
183
a268f085
LC
184(define-public gzip
185 (package
186 (name "gzip")
0bfb9b43 187 (version "1.8")
a268f085 188 (source (origin
87f5d366 189 (method url-fetch)
0db342a5 190 (uri (string-append "mirror://gnu/gzip/gzip-"
28181faf 191 version ".tar.xz"))
a268f085
LC
192 (sha256
193 (base32
0bfb9b43 194 "1lxv3p4iyx7833mlihkn5wfwmz4cys5nybwpz3dfawag8kn6f5zz"))))
a268f085 195 (build-system gnu-build-system)
f50d2669 196 (synopsis "General file (de)compression (using lzw)")
a268f085
LC
197 (arguments
198 ;; FIXME: The test suite wants `less', and optionally Perl.
199 '(#:tests? #f))
200 (description
79c311b8
LC
201 "GNU Gzip provides data compression and decompression utilities; the
202typical extension is \".gz\". Unlike the \"zip\" format, it compresses a single
203file; as a result, it is often used in conjunction with \"tar\", resulting in
204\".tar.gz\" or \".tgz\", etc.")
4a44e743 205 (license license:gpl3+)
a268f085
LC
206 (home-page "http://www.gnu.org/software/gzip/")))
207
208(define-public bzip2
9b1bf330 209 (let ((build-shared-lib
a268f085
LC
210 ;; Build a shared library.
211 '(lambda* (#:key inputs #:allow-other-keys)
f678f6d9 212 (patch-makefile-SHELL "Makefile-libbz2_so")
a268f085
LC
213 (zero? (system* "make" "-f" "Makefile-libbz2_so"))))
214 (install-shared-lib
215 '(lambda* (#:key outputs #:allow-other-keys)
216 (let* ((out (assoc-ref outputs "out"))
217 (libdir (string-append out "/lib")))
218 (for-each (lambda (file)
219 (let ((base (basename file)))
220 (format #t "installing `~a' to `~a'~%"
221 base libdir)
222 (copy-file file
223 (string-append libdir "/" base))))
ab4fab19
LC
224 (find-files "." "^libbz2\\.so")))))
225 (set-cross-environment
226 '(lambda* (#:key target #:allow-other-keys)
227 (substitute* (find-files "." "Makefile")
228 (("CC=.*$")
229 (string-append "CC = " target "-gcc\n"))
230 (("AR=.*$")
231 (string-append "AR = " target "-ar\n"))
232 (("RANLIB=.*$")
233 (string-append "RANLIB = " target "-ranlib\n"))
234 (("^all:(.*)test" _ prerequisites)
235 ;; Remove 'all' -> 'test' dependency.
236 (string-append "all:" prerequisites "\n"))))))
a268f085
LC
237 (package
238 (name "bzip2")
239 (version "1.0.6")
240 (source (origin
87f5d366 241 (method url-fetch)
a268f085
LC
242 (uri (string-append "http://www.bzip.org/" version "/bzip2-"
243 version ".tar.gz"))
244 (sha256
245 (base32
246 "1kfrc7f0ja9fdn6j1y6yir6li818npy6217hvr3wzmnmzhs8z152"))))
247 (build-system gnu-build-system)
248 (arguments
249 `(#:modules ((guix build gnu-build-system)
250 (guix build utils)
251 (srfi srfi-1))
252 #:phases
ab4fab19
LC
253 ,(if (%current-target-system)
254
255 ;; Cross-compilation: use the cross tools.
256 `(alist-cons-before
257 'build 'build-shared-lib ,build-shared-lib
258 (alist-cons-after
9b1bf330
LC
259 'install 'install-shared-lib ,install-shared-lib
260 (alist-replace 'configure ,set-cross-environment
261 %standard-phases)))
ab4fab19
LC
262
263 ;; Native compilation: build the shared library.
264 `(alist-cons-before
265 'build 'build-shared-lib ,build-shared-lib
266 (alist-cons-after
9b1bf330
LC
267 'install 'install-shared-lib ,install-shared-lib
268 (alist-delete 'configure %standard-phases))))
ab4fab19 269
a268f085 270 #:make-flags (list (string-append "PREFIX="
ab4fab19
LC
271 (assoc-ref %outputs "out")))
272
273 ;; Don't attempt to run the tests when cross-compiling.
274 ,@(if (%current-target-system)
275 '(#:tests? #f)
276 '())))
35b9e423 277 (synopsis "High-quality data compression program")
a268f085
LC
278 (description
279 "bzip2 is a freely available, patent free (see below), high-quality data
280compressor. It typically compresses files to within 10% to 15% of the best
281available techniques (the PPM family of statistical compressors), whilst
282being around twice as fast at compression and six times faster at
283decompression.")
166191b3 284 (license (license:non-copyleft "file://LICENSE"
4a44e743 285 "See LICENSE in the distribution."))
a268f085
LC
286 (home-page "http://www.bzip.org/"))))
287
669b7b83
RW
288(define-public lbzip2
289 (package
290 (name "lbzip2")
291 (version "2.5")
292 (source (origin
293 (method url-fetch)
294 (uri (string-append "http://archive.lbzip2.org/lbzip2-"
295 version ".tar.gz"))
296 (sha256
297 (base32
298 "1sahaqc5bw4i0iyri05syfza4ncf5cml89an033fspn97klmxis6"))))
299 (build-system gnu-build-system)
300 (synopsis "Parallel bzip2 compression utility")
301 (description
302 "lbzip2 is a multi-threaded compression utility with support for the
303bzip2 compressed file format. lbzip2 can process standard bz2 files in
304parallel. It uses POSIX threading model (pthreads), which allows it to take
305full advantage of symmetric multiprocessing (SMP) systems. It has been proven
306to scale linearly, even to over one hundred processor cores. lbzip2 is fully
307compatible with bzip2 – both at file format and command line level.")
308 (home-page "http://www.lbzip2.org/")
309 (license license:gpl3+)))
310
5d47eab0
EF
311(define-public pbzip2
312 (package
313 (name "pbzip2")
314 (version "1.1.12")
315 (source (origin
316 (method url-fetch)
21b2ec4d
EF
317 (uri (string-append "https://launchpad.net/pbzip2/"
318 (version-major+minor version) "/" version
319 "/+download/" name "-" version ".tar.gz"))
5d47eab0
EF
320 (sha256
321 (base32
322 "1vk6065dv3a47p86vmp8hv3n1ygd9hraz0gq89gvzlx7lmcb6fsp"))))
323 (build-system gnu-build-system)
324 (inputs
b3546174 325 `(("bzip2" ,bzip2)))
5d47eab0
EF
326 (arguments
327 `(#:tests? #f ; no tests
328 #:phases (modify-phases %standard-phases
21b2ec4d
EF
329 (delete 'configure))
330 #:make-flags (list (string-append "PREFIX=" %output))))
5d47eab0
EF
331 (home-page "http://compression.ca/pbzip2/")
332 (synopsis "Parallel bzip2 implementation")
333 (description
334 "Pbzip2 is a parallel implementation of the bzip2 block-sorting file
335compressor that uses pthreads and achieves near-linear speedup on SMP machines.
21b2ec4d 336The output of this version is fully compatible with bzip2 v1.0.2 (i.e. anything
5d47eab0
EF
337compressed with pbzip2 can be decompressed with bzip2).")
338 (license (license:non-copyleft "file://COPYING"
21b2ec4d 339 "See COPYING in the distribution."))))
5d47eab0 340
a268f085
LC
341(define-public xz
342 (package
343 (name "xz")
4655f515 344 (version "5.2.2")
a268f085 345 (source (origin
87f5d366 346 (method url-fetch)
52d76b64
LC
347 (uri (list (string-append "http://tukaani.org/xz/xz-" version
348 ".tar.gz")
349 (string-append "http://multiprecision.org/guix/xz-"
350 version ".tar.gz")))
a268f085
LC
351 (sha256
352 (base32
4655f515 353 "18h2k4jndhzjs8ln3a54qdnfv59y6spxiwh9gpaqniph6iflvpvk"))))
a268f085 354 (build-system gnu-build-system)
35b9e423 355 (synopsis "General-purpose data compression")
a268f085
LC
356 (description
357 "XZ Utils is free general-purpose data compression software with high
358compression ratio. XZ Utils were written for POSIX-like systems, but also
359work on some not-so-POSIX systems. XZ Utils are the successor to LZMA Utils.
360
361The core of the XZ Utils compression code is based on LZMA SDK, but it has
362been modified quite a lot to be suitable for XZ Utils. The primary
363compression algorithm is currently LZMA2, which is used inside the .xz
364container format. With typical files, XZ Utils create 30 % smaller output
365than gzip and 15 % smaller output than bzip2.")
38bbd61d 366 (license (list license:gpl2+ license:lgpl2.1+)) ; bits of both
a268f085 367 (home-page "http://tukaani.org/xz/")))
c6eac761
LC
368
369(define-public lzo
370 (package
371 (name "lzo")
c0ec516d 372 (version "2.09")
c6eac761
LC
373 (source
374 (origin
375 (method url-fetch)
376 (uri (string-append "http://www.oberhumer.com/opensource/lzo/download/lzo-"
377 version ".tar.gz"))
378 (sha256
379 (base32
c0ec516d 380 "0k5kpj3jnsjfxqqkblpfpx0mqcy86zs5fhjhgh2kq1hksg7ag57j"))))
c6eac761 381 (build-system gnu-build-system)
165fd9d5 382 (arguments '(#:configure-flags '("--enable-shared")))
c6eac761
LC
383 (home-page "http://www.oberhumer.com/opensource/lzo")
384 (synopsis
e881752c 385 "Data compression library suitable for real-time data de-/compression")
c6eac761
LC
386 (description
387 "LZO is a data compression library which is suitable for data
388de-/compression in real-time. This means it favours speed over
389compression ratio.
390
391LZO is written in ANSI C. Both the source code and the compressed data
392format are designed to be portable across platforms.")
4a44e743 393 (license license:gpl2+)))
0f323dad 394
1a0a5509 395(define-public python-lzo
396 (package
397 (name "python-lzo")
398 (version "1.11")
399 (source
400 (origin
401 (method url-fetch)
402 (uri (pypi-uri "python-lzo" version))
403 (sha256
404 (base32
405 "11p3ifg14p086byhhin6azx5svlkg8dzw2b5abixik97xd6fm81q"))))
406 (build-system python-build-system)
407 (arguments
408 `(#:test-target "check"
409 #:phases
410 (modify-phases %standard-phases
411 (add-after 'unpack 'patch-setuppy
412 (lambda _
413 (substitute* "setup.py"
414 (("include_dirs.append\\(.*\\)")
415 (string-append "include_dirs.append('"
416 (assoc-ref %build-inputs "lzo")
417 "/include/lzo"
418 "')")))
419 #t)))))
420 (inputs
421 `(("lzo" ,lzo)))
422 (home-page "https://github.com/jd-boyd/python-lzo")
423 (synopsis "Python bindings for the LZO data compression library")
424 (description
425 "Python-LZO provides Python bindings for LZO, i.e. you can access
426the LZO library from your Python scripts thereby compressing ordinary
427Python strings.")
428 (license license:gpl2+)))
429
430(define-public python2-lzo
431 (package-with-python2 python-lzo))
432
a9f48ff0
EB
433(define-public lzop
434 (package
435 (name "lzop")
436 (version "1.03")
437 (source
438 (origin
439 (method url-fetch)
440 (uri (string-append "http://www.lzop.org/download/lzop-"
441 version ".tar.gz"))
442 (sha256
443 (base32
444 "1jdjvc4yjndf7ihmlcsyln2rbnbaxa86q4jskmkmm7ylfy65nhn1"))))
445 (build-system gnu-build-system)
446 (inputs `(("lzo" ,lzo)))
447 (home-page "http://www.lzop.org/")
448 (synopsis "Compress or expand files")
449 (description
450 "Lzop is a file compressor which is very similar to gzip. Lzop uses the
451LZO data compression library for compression services, and its main advantages
452over gzip are much higher compression and decompression speed (at the cost of
453some compression ratio).")
454 (license license:gpl2+)))
455
0f323dad
LC
456(define-public lzip
457 (package
458 (name "lzip")
275a7711 459 (version "1.16")
0f323dad
LC
460 (source (origin
461 (method url-fetch)
462 (uri (string-append "mirror://savannah/lzip/lzip-"
463 version ".tar.gz"))
464 (sha256
465 (base32
275a7711 466 "0l9724rw1l3hg2ldr3n7ihqich4m9nc6y7l302bvdj4jmxdw530j"))))
0f323dad
LC
467 (build-system gnu-build-system)
468 (home-page "http://www.nongnu.org/lzip/lzip.html")
469 (synopsis "Lossless data compressor based on the LZMA algorithm")
470 (description
471 "Lzip is a lossless data compressor with a user interface similar to the
472one of gzip or bzip2. Lzip decompresses almost as fast as gzip and compresses
473more than bzip2, which makes it well suited for software distribution and data
474archiving. Lzip is a clean implementation of the LZMA algorithm.")
475 (license license:gpl3+)))
b357faac
AE
476
477(define-public sharutils
478 (package
479 (name "sharutils")
9a59ce24 480 (version "4.15.2")
b357faac
AE
481 (source
482 (origin
483 (method url-fetch)
484 (uri (string-append "mirror://gnu/sharutils/sharutils-"
485 version ".tar.xz"))
486 (sha256
487 (base32
9a59ce24 488 "16isapn8f39lnffc3dp4dan05b7x6mnc76v6q5nn8ysxvvvwy19b"))))
b357faac
AE
489 (build-system gnu-build-system)
490 (inputs
491 `(("which" ,which)))
492 (arguments
493 `(#:phases
494 (alist-cons-after
495 'patch-source-shebangs 'unpatch-source-shebang
496 ;; revert the patch-shebang phase on a script which is
497 ;; in fact test data
d4bf49b1 498 (lambda _
b357faac
AE
499 (substitute* "tests/shar-1.ok"
500 (((which "sh")) "/bin/sh")))
501 %standard-phases)))
502 (home-page "http://www.gnu.org/software/sharutils/")
503 (synopsis "Archives in shell scripts, uuencode/uudecode")
504 (description
79c311b8
LC
505 "GNU sharutils is a package for creating and manipulating shell
506archives that can be readily emailed. A shell archive is a file that can be
e881752c 507processed by a Bourne-type shell to unpack the original collection of files.
79c311b8 508This package is mostly for compatibility and historical interest.")
b357faac 509 (license license:gpl3+)))
28469ab0 510
646898b3
RW
511(define-public sfarklib
512 (package
513 (name "sfarklib")
979f9e8a 514 (version "2.24")
646898b3 515 (source (origin
979f9e8a
RW
516 (method url-fetch)
517 (uri (string-append "https://github.com/raboof/sfArkLib/archive/"
518 version ".tar.gz"))
519 (file-name (string-append name "-" version ".tar.gz"))
646898b3
RW
520 (sha256
521 (base32
979f9e8a 522 "0bzs2d98rk1xw9qwpnc7gmlbxwmwc3dg1rpn310afy9pq1k9clzi"))))
646898b3
RW
523 (build-system gnu-build-system)
524 (arguments
525 `(#:tests? #f ;no "check" target
526 #:phases
527 (modify-phases %standard-phases
528 (replace 'configure
529 (lambda* (#:key outputs #:allow-other-keys)
530 (substitute* "Makefile"
531 (("/usr/local") (assoc-ref outputs "out")))
532 #t)))))
533 (inputs
534 `(("zlib" ,zlib)))
535 (home-page "https://github.com/raboof/sfArkLib")
536 (synopsis "Library for SoundFont decompression")
537 (description
538 "SfArkLib is a C++ library for decompressing SoundFont files compressed
539with the sfArk algorithm.")
540 (license license:gpl3+)))
541
b5ad1659 542(define-public sfarkxtc
698bd297 543 (let ((commit "b5e0a2ba3921f019d74d4b92bd31c36dd19d2cf1"))
b5ad1659
RW
544 (package
545 (name "sfarkxtc")
698bd297 546 (version (string-take commit 10))
b5ad1659
RW
547 (source (origin
548 ;; There are no release tarballs, so we just fetch the latest
549 ;; commit at this time.
550 (method git-fetch)
551 (uri (git-reference
552 (url "https://github.com/raboof/sfarkxtc.git")
698bd297 553 (commit commit)))
b5ad1659
RW
554 (sha256
555 (base32
556 "0f5x6i46qfl6ry21s7g2p4sd4b2r1g4fb03yqi2vv4kq3saryhvj"))))
557 (build-system gnu-build-system)
558 (arguments
559 `(#:tests? #f ;no "check" target
560 #:phases
561 (modify-phases %standard-phases
562 (replace 'configure
563 (lambda* (#:key outputs #:allow-other-keys)
564 (substitute* "Makefile"
565 (("/usr/local") (assoc-ref outputs "out")))
566 #t)))))
567 (inputs
568 `(("zlib" ,zlib)
569 ("sfarklib" ,sfarklib)))
570 (home-page "https://github.com/raboof/sfarkxtc")
571 (synopsis "Basic sfArk decompressor")
572 (description "SfArk extractor converts SoundFonts in the compressed legacy
573sfArk file format to the uncompressed sf2 format.")
698bd297 574 (license license:gpl3+))))
b5ad1659 575
27f76fe6
TUBK
576(define-public libmspack
577 (package
578 (name "libmspack")
579 (version "0.5")
580 (source
581 (origin
582 (method url-fetch)
583 (uri (string-append "http://www.cabextract.org.uk/libmspack/libmspack-"
584 version "alpha.tar.gz"))
585 (sha256
586 (base32 "04413hynb7zizxnkgy9riik3612dwirkpr6fcjrnfl2za9sz4rw9"))))
587 (build-system gnu-build-system)
588 (home-page "http://www.cabextract.org.uk/libmspack/")
589 (synopsis "Compression tools for some formats used by Microsoft")
590 (description
591 "The purpose of libmspack is to provide both compression and
592decompression of some loosely related file formats used by Microsoft.")
593 (license license:lgpl2.1+)))
73f542c3
EB
594
595(define-public perl-compress-raw-bzip2
596 (package
597 (name "perl-compress-raw-bzip2")
598 (version "2.068")
599 (source
600 (origin
601 (method url-fetch)
602 (uri (string-append "mirror://cpan/authors/id/P/PM/PMQS/"
603 "Compress-Raw-Bzip2-" version ".tar.gz"))
604 (sha256
605 (base32
606 "16hl58xppckldz05zdyid1l5gpaykzwvkq682h3rc3nilbhgjqqg"))))
607 (build-system perl-build-system)
608 ;; TODO: Use our bzip2 package.
609 (home-page "http://search.cpan.org/dist/Compress-Raw-Bzip2")
610 (synopsis "Low-level interface to bzip2 compression library")
611 (description "This module provides a Perl interface to the bzip2
612compression library.")
613 (license (package-license perl))))
8e18514a
EB
614
615(define-public perl-compress-raw-zlib
616 (package
617 (name "perl-compress-raw-zlib")
618 (version "2.068")
619 (source
620 (origin
621 (method url-fetch)
622 (uri (string-append "mirror://cpan/authors/id/P/PM/PMQS/"
623 "Compress-Raw-Zlib-" version ".tar.gz"))
624 (sha256
625 (base32
626 "06q7n87g26nn5gv4z2p31ca32f6zk124hqxc25rfgkjd3qi5798i"))))
627 (build-system perl-build-system)
628 (inputs
629 `(("zlib" ,zlib)))
630 (arguments
631 `(#:phases (modify-phases %standard-phases
632 (add-before
40b084a3 633 'configure 'configure-zlib
8e18514a
EB
634 (lambda* (#:key inputs #:allow-other-keys)
635 (call-with-output-file "config.in"
636 (lambda (port)
637 (format port "
638BUILD_ZLIB = False
639INCLUDE = ~a/include
640LIB = ~:*~a/lib
641OLD_ZLIB = False
642GZIP_OS_CODE = AUTO_DETECT"
643 (assoc-ref inputs "zlib")))))))))
644 (home-page "http://search.cpan.org/dist/Compress-Raw-Zlib")
645 (synopsis "Low-level interface to zlib compression library")
646 (description "This module provides a Perl interface to the zlib
647compression library.")
648 (license (package-license perl))))
8aaafd34
EB
649
650(define-public perl-io-compress
651 (package
652 (name "perl-io-compress")
653 (version "2.068")
654 (source
655 (origin
656 (method url-fetch)
657 (uri (string-append "mirror://cpan/authors/id/P/PM/PMQS/"
658 "IO-Compress-" version ".tar.gz"))
659 (sha256
660 (base32
661 "0dy0apjp7j9dfkzfjspjd3z9gh26srx5vac72g59bkkz1jf8s1gs"))))
662 (build-system perl-build-system)
663 (propagated-inputs
664 `(("perl-compress-raw-zlib" ,perl-compress-raw-zlib) ; >=2.068
665 ("perl-compress-raw-bzip2" ,perl-compress-raw-bzip2))) ; >=2.068
666 (home-page "http://search.cpan.org/dist/IO-Compress")
667 (synopsis "IO Interface to compressed files/buffers")
668 (description "IO-Compress provides a Perl interface to allow reading and
669writing of compressed data created with the zlib and bzip2 libraries.")
670 (license (package-license perl))))
82aa2a28
LF
671
672(define-public lz4
673 (package
674 (name "lz4")
fc89cb69 675 (version "1.7.4.2")
82aa2a28
LF
676 (source
677 (origin
678 (method url-fetch)
679 (uri (string-append "https://github.com/Cyan4973/lz4/archive/"
fc89cb69 680 "v" version ".tar.gz"))
82aa2a28 681 (sha256
fc89cb69 682 (base32 "0l39bymif15rmmfz7h6wvrr853rix4wj8wbqq8z8fm49xa7gx9fb"))
82aa2a28
LF
683 (file-name (string-append name "-" version ".tar.gz"))))
684 (build-system gnu-build-system)
fc89cb69 685 (native-inputs `(("valgrind" ,valgrind))) ; for tests
82aa2a28
LF
686 (arguments
687 `(#:test-target "test"
688 #:parallel-tests? #f ; tests fail if run in parallel
689 #:make-flags (list "CC=gcc"
690 (string-append "PREFIX=" (assoc-ref %outputs "out")))
691 #:phases (modify-phases %standard-phases
fc89cb69 692 (delete 'configure)))) ; no configure script
82aa2a28
LF
693 (home-page "https://github.com/Cyan4973/lz4")
694 (synopsis "Compression algorithm focused on speed")
695 (description "LZ4 is a lossless compression algorithm, providing
696compression speed at 400 MB/s per core (0.16 Bytes/cycle). It also features an
697extremely fast decoder, with speed in multiple GB/s per core (0.71 Bytes/cycle).
698A high compression derivative, called LZ4_HC, is also provided. It trades CPU
699time for compression ratio.")
700 ;; The libraries (lz4, lz4hc, and xxhash are BSD licenced. The command
701 ;; line interface programs (lz4, fullbench, fuzzer, datagen) are GPL2+.
702 (license (list license:bsd-2 license:gpl2+))))
dd8d6d65 703
1ae60db8 704(define-public python-lz4
705 (package
706 (name "python-lz4")
707 (version "0.8.2")
708 (source
709 (origin
710 (method url-fetch)
711 (uri (pypi-uri "lz4" version))
712 (sha256
713 (base32
714 "1irad4sq4hdr30fr53smvv3zzk4rddcf9b4jx19w8s9xsxhr1x3b"))))
715 (build-system python-build-system)
716 (native-inputs
717 `(("python-nose" ,python-nose)))
718 (home-page "https://github.com/python-lz4/python-lz4")
719 (synopsis "LZ4 Bindings for Python")
720 (description
721 "This package provides python bindings for the lz4 compression library
722by Yann Collet. The project contains bindings for the LZ4 block format and
723the LZ4 frame format.")
724 (license license:bsd-3)))
725
726(define-public python2-lz4
727 (package-with-python2 python-lz4))
728
dd8d6d65
SB
729(define-public squashfs-tools
730 (package
731 (name "squashfs-tools")
732 (version "4.3")
733 (source (origin
734 (method url-fetch)
de67e922
LF
735 (uri (string-append "mirror://sourceforge/squashfs/squashfs/"
736 "squashfs" version "/"
dd8d6d65
SB
737 "squashfs" version ".tar.gz"))
738 (sha256
739 (base32
740 "1xpklm0y43nd9i6jw43y2xh5zvlmj9ar2rvknh0bh7kv8c95aq0d"))))
741 (build-system gnu-build-system)
742 (arguments
743 '(#:tests? #f ; no check target
744 #:make-flags
745 (list "CC=gcc"
746 "XZ_SUPPORT=1"
747 "LZO_SUPPORT=1"
748 "LZ4_SUPPORT=1"
749 (string-append "INSTALL_DIR=" %output "/bin"))
750 #:phases
751 (modify-phases %standard-phases
752 (replace 'configure
753 (lambda _
754 (chdir "squashfs-tools"))))))
755 (inputs
756 `(("lz4" ,lz4)
757 ("lzo" ,lzo)
758 ("xz" ,xz)
759 ("zlib" ,zlib)))
760 (home-page "http://squashfs.sourceforge.net/")
8f65585b 761 (synopsis "Tools to create and extract squashfs file systems")
dd8d6d65 762 (description
8f65585b 763 "Squashfs is a highly compressed read-only file system for Linux. It uses
dd8d6d65
SB
764zlib to compress files, inodes, and directories. All blocks are packed to
765minimize the data overhead, and block sizes of between 4K and 1M are supported.
766It is intended to be used for archival use, for live CDs, and for embedded
767systems where low overhead is needed. This package allows you to create and
8f65585b 768extract such file systems.")
dd8d6d65 769 (license license:gpl2+)))
820dc3f5
JM
770
771(define-public pigz
772 (package
773 (name "pigz")
774 (version "2.3.3")
775 (source (origin
776 (method url-fetch)
777 (uri (string-append "http://zlib.net/pigz/"
778 name "-" version ".tar.gz"))
779 (sha256
780 (base32
781 "172hdf26k4zmm7z8md7nl0dph2a7mhf3x7slb9bhfyff6as6g2sf"))))
782 (build-system gnu-build-system)
783 (arguments
784 `(#:phases
785 (modify-phases %standard-phases
786 (delete 'configure)
787 (replace 'install
788 (lambda* (#:key outputs #:allow-other-keys)
789 (let* ((out (assoc-ref outputs "out"))
790 (bin (string-append out "/bin"))
791 (man (string-append out "/share/man/man1")))
792 (install-file "pigz" bin)
793 (symlink "pigz" (string-append bin "/unpigz"))
794 (install-file "pigz.1" man)
795 #t))))
796 #:make-flags (list "CC=gcc")
797 #:test-target "tests"))
798 (inputs `(("zlib" ,zlib)))
799 (home-page "http://zlib.net/pigz/")
800 (synopsis "Parallel implementation of gzip")
801 (description
802 "This package provides a parallel implementation of gzip that exploits
803multiple processors and multiple cores when compressing data.")
804
805 ;; Things under zopfli/ are under ASL2.0, but 4 files at the top-level,
806 ;; written by Mark Adler, are under another non-copyleft license.
807 (license license:asl2.0)))
23f3cbb8
BW
808
809(define-public pixz
810 (package
811 (name "pixz")
812 (version "1.0.6")
813 (source (origin
814 (method url-fetch)
815 (uri (string-append
816 "https://github.com/vasi/pixz/releases/download/v" version
817 "/pixz-" version ".tar.xz"))
818 (sha256
819 (base32
820 "1s3j7zw6j5zi3fhdxg287ndr3wf6swac7z21mqd1pyiln530gi82"))))
821 (build-system gnu-build-system)
822 (native-inputs
823 `(("pkg-config" ,pkg-config)
824 ("libarchive" ,libarchive)))
825 (home-page "https://github.com/vasi/pixz")
826 (synopsis "Parallel indexing implementation of LZMA")
827 (description
828 "The existing XZ Utils provide great compression in the .xz file format,
829but they produce just one big block of compressed data. Pixz instead produces
830a collection of smaller blocks which makes random access to the original data
831possible and can compress in parallel. This is especially useful for large
832tarballs.")
833 (license license:bsd-2)))
69d9792a
EB
834
835(define-public brotli
836 (let ((commit "e992cce7a174d6e2b3486616499d26bb0bad6448")
837 (revision "1"))
838 (package
839 (name "brotli")
840 (version (string-append "0.1-" revision "."
841 (string-take commit 7)))
842 (source (origin
843 (method git-fetch)
844 (uri (git-reference
845 (url "https://github.com/bagder/libbrotli.git")
846 (commit commit)
847 (recursive? #t)))
848 (file-name (string-append name "-" version ".tar.xz"))
849 (sha256
850 (base32
851 "1qxxsasvwbbbh6dl3138y9h3fg0q2v7xdk5jjc690bdg7g1wrj6n"))
852 (modules '((guix build utils)))
853 (snippet
854 ;; This is a recursive submodule that is unnecessary for this
855 ;; package, so delete it.
856 '(delete-file-recursively "brotli/terryfy"))))
857 (build-system gnu-build-system)
858 (native-inputs
859 `(("autoconf" ,autoconf)
860 ("automake" ,automake)
861 ("libtool" ,libtool)))
862 (arguments
863 `(#:phases (modify-phases %standard-phases
864 (add-after 'unpack 'autogen
865 (lambda _
866 (mkdir "m4")
867 (zero? (system* "autoreconf" "-vfi")))))))
868 (home-page "https://github.com/bagder/libbrotli/")
869 (synopsis "Implementation of the Brotli compression algorithm")
870 (description
871 "Brotli is a general-purpose lossless compression algorithm. It is
872similar in speed to deflate but offers denser compression. This package
873provides encoder and a decoder libraries: libbrotlienc and libbrotlidec,
874respectively, based on the reference implementation from Google.")
875 (license license:expat))))
3fd4b90d
DM
876
877(define-public cabextract
878 (package
879 (name "cabextract")
880 (version "1.6")
881 (source (origin
882 (method url-fetch)
883 (uri (string-append
884 "http://cabextract.org.uk/cabextract-" version ".tar.gz"))
885 (sha256
886 (base32
887 "1ysmmz25fjghq7mxb2anyyvr1ljxqxzi4piwjhk0sdamcnsn3rnf"))))
888 (build-system gnu-build-system)
889 (arguments '(#:configure-flags '("--with-external-libmspack")))
890 (native-inputs
891 `(("pkg-config" ,pkg-config)))
892 (inputs
893 `(("libmspack" ,libmspack)))
894 (home-page "http://www.cabextract.org.uk/")
895 (synopsis "Tool to unpack Cabinet archives")
896 (description "Extracts files out of Microsoft Cabinet (.cab) archives")
897 ;; Some source files specify gpl2+, lgpl2+, however COPYING is gpl3.
898 (license license:gpl3+)))
0b073506
TGR
899
900(define-public xdelta
901 (package
902 (name "xdelta")
903 (version "3.1.0")
904 (source
905 (origin
906 (method url-fetch)
907 (uri (string-append "https://github.com/jmacd/xdelta/archive/v"
908 version ".tar.gz"))
909 (sha256
910 (base32
911 "17g2pbbqy6h20qgdjq7ykib7kg5ajh8fwbsfgyjqg8pwg19wy5bm"))
912 (file-name (string-append name "-" version ".tar.gz"))
913 (snippet
914 ;; This file isn't freely distributable and has no effect on building.
915 '(delete-file "xdelta3/draft-korn-vcdiff.txt"))))
916 (build-system gnu-build-system)
917 (native-inputs
918 `(("autoconf" ,autoconf)
919 ("automake" ,automake)))
920 (arguments
921 `(#:phases
922 (modify-phases %standard-phases
923 (add-after 'unpack 'enter-build-directory
924 (lambda _ (chdir "xdelta3")))
925 (add-before 'configure 'autoconf
926 (lambda _ (zero? (system* "autoreconf" "-vfi")))))))
927 (home-page "http://xdelta.com")
928 (synopsis "Delta encoder for binary files")
929 (description "xdelta encodes only the differences between two binary files
930using the VCDIFF algorithm and patch file format described in RFC 3284. It can
931also be used to apply such patches. xdelta is similar to @command{diff} and
932@command{patch}, but is not limited to plain text and does not generate
933human-readable output.")
934 (license license:asl2.0)))
389eb3fa
TGR
935
936(define-public lrzip
937 (package
938 (name "lrzip")
666619d0 939 (version "0.631")
389eb3fa
TGR
940 (source
941 (origin
942 (method url-fetch)
943 (uri (string-append
944 "http://ck.kolivas.org/apps/lrzip/lrzip-" version ".tar.bz2"))
945 (sha256
946 (base32
666619d0 947 "0mb449vmmwpkalq732jdyginvql57nxyd31sszb108yps1lf448d"))))
389eb3fa
TGR
948 (build-system gnu-build-system)
949 (native-inputs
950 `(;; nasm is only required when building for 32-bit x86 platforms
951 ,@(if (string-prefix? "i686" (or (%current-target-system)
952 (%current-system)))
953 `(("nasm" ,nasm))
954 '())
955 ("perl" ,perl)))
956 (inputs
957 `(("bzip2" ,bzip2)
958 ("lzo" ,lzo)
959 ("zlib" ,zlib)))
960 (home-page "http://ck.kolivas.org/apps/lrzip/")
961 (synopsis "Large file compressor with a very high compression ratio")
962 (description "lrzip is a compression utility that uses long-range
963redundancy reduction to improve the subsequent compression ratio of
964larger files. It can then further compress the result with the ZPAQ or
965LZMA algorithms for maximum compression, or LZO for maximum speed. This
966choice between size or speed allows for either better compression than
967even LZMA can provide, or a higher speed than gzip while compressing as
968well as bzip2.")
969 (license (list license:gpl3+
970 license:public-domain)))) ; most files in lzma/
e4c2136d
DC
971
972(define-public snappy
973 (package
974 (name "snappy")
9baab9ae 975 (version "1.1.4")
e4c2136d
DC
976 (source (origin
977 (method url-fetch)
978 (uri (string-append
979 "https://github.com/google/snappy/releases/download/"
980 version "/" name "-" version ".tar.gz"))
981 (sha256
982 (base32
9baab9ae 983 "0mq0nz8gbi1sp3y6xcg0a6wbvnd6gc717f3vh2xrjmfj5w9gwjqk"))))
e4c2136d
DC
984 (build-system gnu-build-system)
985 (home-page "https://github.com/google/snappy")
986 (synopsis "Fast compressor/decompressor")
987 (description "Snappy is a compression/decompression library. It does not
988aim for maximum compression, or compatibility with any other compression library;
989instead, it aims for very high speeds and reasonable compression. For instance,
990compared to the fastest mode of zlib, Snappy is an order of magnitude faster
991for most inputs, but the resulting compressed files are anywhere from 20% to
992100% bigger.")
993 (license license:asl2.0)))
adbd7faf
KK
994
995(define-public p7zip
996 (package
997 (name "p7zip")
998 (version "16.02")
999 (source (origin
1000 (method url-fetch)
1001 (uri (string-append "mirror://sourceforge/" name "/" name "/"
1002 version "/" name "_" version
1003 "_src_all.tar.bz2"))
1004 (sha256
1005 (base32
1006 "07rlwbbgszq8i7m8jh3x6j2w2hc9a72dc7fmqawnqkwlwb00mcjy"))
1007 (modules '((guix build utils)))
1008 (snippet
1009 '(begin
1010 ;; Remove non-free source files
1011 (for-each delete-file
1012 (append
1013 (find-files "CPP/7zip/Compress" "Rar.*")
1014 (find-files "CPP/7zip/Crypto" "Rar.*")
1015 (find-files "DOC/unRarLicense.txt")
1016 (find-files "Utils/file_Codecs_Rar_so.py")))
1017 (delete-file-recursively "CPP/7zip/Archive/Rar")
1018 (delete-file-recursively "CPP/7zip/Compress/Rar")
1019 #t))
1ac675a5
EF
1020 (patches (search-patches "p7zip-CVE-2016-9296.patch"
1021 "p7zip-remove-unused-code.patch"))))
adbd7faf
KK
1022 (build-system gnu-build-system)
1023 (arguments
1024 `(#:make-flags
1025 (list (string-append "DEST_HOME=" (assoc-ref %outputs "out")) "all3")
1026 #:phases
1027 (modify-phases %standard-phases
1028 (replace 'configure
1029 (lambda* (#:key system outputs #:allow-other-keys)
1030 (zero? (system* "cp"
1031 (let ((system ,(or (%current-target-system)
1032 (%current-system))))
1033 (cond
1034 ((string-prefix? "x86_64" system)
1035 "makefile.linux_amd64_asm")
1036 ((string-prefix? "i686" system)
1037 "makefile.linux_x86_asm_gcc_4.X")
1038 (else
1039 "makefile.linux_any_cpu_gcc_4.X")))
1040 "makefile.machine"))))
1041 (replace 'check
1042 (lambda _
1043 (and (zero? (system* "make" "test"))
1044 (zero? (system* "make" "test_7z"))
1045 (zero? (system* "make" "test_7zr"))))))))
1046 (inputs
1047 (let ((system (or (%current-target-system)
1048 (%current-system))))
1049 `(,@(cond ((string-prefix? "x86_64" system)
1050 `(("yasm" ,yasm)))
1051 ((string-prefix? "i686" system)
1052 `(("nasm" ,nasm)))
1053 (else '())))))
1054 (home-page "http://p7zip.sourceforge.net/")
1055 (synopsis "Command-line file archiver with high compression ratio")
1056 (description "p7zip is a command-line port of 7-Zip, a file archiver that
1057handles the 7z format which features very high compression ratios.")
1058 (license (list license:lgpl2.1+
1059 license:gpl2+
1060 license:public-domain))))
618089f9
MB
1061
1062(define-public gzstream
1063 (package
1064 (name "gzstream")
1065 (version "1.5")
1066 (source (origin
1067 (method url-fetch)
1068 (uri
1069 ;; No versioned URL, but last release was in 2003.
1070 "http://www.cs.unc.edu/Research/compgeom/gzstream/gzstream.tgz")
1071 (file-name (string-append name "-" version ".tgz"))
1072 (sha256
1073 (base32
1074 "00y19pqjsdj5zcrx4p9j56pl73vayfwnb7y2hvp423nx0cwv5b4r"))
1075 (modules '((guix build utils)))
1076 (snippet
1077 ;; Remove pre-compiled object.
1078 '(delete-file "gzstream.o"))))
1079 (build-system gnu-build-system)
1080 (arguments
1081 `(#:test-target "test"
1082 #:phases
1083 (modify-phases %standard-phases
1084 (delete 'configure)
1085 (replace 'install
1086 (lambda* (#:key outputs #:allow-other-keys)
1087 (let* ((out (assoc-ref outputs "out"))
1088 (lib (string-append out "/lib"))
1089 (include (string-append out "/include")))
1090 (install-file "libgzstream.a" lib)
1091 (install-file "gzstream.h" include)
1092 #t))))))
1093 (propagated-inputs `(("zlib" ,zlib)))
1094 (home-page "http://www.cs.unc.edu/Research/compgeom/gzstream/")
1095 (synopsis "Compressed C++ iostream")
1096 (description "gzstream is a small library for providing zlib
1097functionality in a C++ iostream.")
1098 (license license:lgpl2.1+)))
36df995c
TGR
1099
1100(define-public zpaq
1101 (package
1102 (name "zpaq")
1103 (version "7.15")
1104 (source
1105 (origin
1106 (method url-fetch/zipbomb)
1107 (uri (string-append "http://mattmahoney.net/dc/zpaq"
1108 (string-delete #\. version) ".zip"))
1109 (sha256
1110 (base32
1111 "066l94yyladlfzri877nh2dhkvspagjn3m5bmv725fmhkr9c4pp8"))
1112 (modules '((guix build utils)))
1113 (snippet
1114 ;; Delete irrelevant pre-compiled binaries.
1115 '(for-each delete-file (find-files "." "\\.exe$")))))
1116 (build-system gnu-build-system)
1117 (arguments
1118 `(#:phases
1119 (modify-phases %standard-phases
1120 (delete 'configure)) ; no ‘configure’ script
1121 #:make-flags
1122 (list
1123 (string-append "CPPFLAGS=-Dunix"
1124 ,(match (or (%current-target-system)
1125 (%current-system))
1126 ("x86_64-linux" "")
1127 ("i686-linux" "")
1128 (_ " -DNOJIT")))
1129 ;; These should be safe, lowest-common-denominator instruction sets,
1130 ;; allowing for some optimisation while remaining reproducible.
effd7198 1131 (string-append "CXXFLAGS=-O3 -DNDEBUG"
36df995c
TGR
1132 ,(match (or (%current-target-system)
1133 (%current-system))
effd7198
EF
1134 ("x86_64-linux" " -march=nocona -mtune=generic")
1135 ("i686-linux" " -march=i686 -mtune=generic")
1136 ("armhf-linux" " -mtune=generic-armv7-a")
36df995c
TGR
1137 (_ "")))
1138 (string-append "PREFIX="
1139 (assoc-ref %outputs "out")))))
1140 (native-inputs
1141 `(("perl" ,perl))) ; for pod2man
1142 (home-page "http://mattmahoney.net/dc/zpaq.html")
1143 (synopsis "Incremental journaling archiver")
1144 (description "ZPAQ is a command-line archiver for realistic situations with
1145many duplicate and already compressed files. It backs up only those files
1146modified since the last update. All previous versions remain untouched and can
1147be independently recovered. Identical files are only stored once (known as
1148@dfn{de-duplication}). Archives can also be encrypted.
1149
1150ZPAQ is intended to back up user data, not entire operating systems. It ignores
1151owner and group IDs, ACLs, extended attributes, or special file types like
1152devices, sockets, or named pipes. It does not follow or restore symbolic links
1153or junctions, and always follows hard links.")
1154 (license (list license:public-domain
1155 ;; libzpaq.cpp contains a mix of public-domain and
1156 ;; expat-licenced (or ‘MIT’) code.
1157 license:expat))))
0da8313c
JD
1158
1159(define-public unrar
1160 (package
1161 (name "unrar")
1162 (version "0.0.1")
1163 (source (origin
1164 (method url-fetch)
1165 (uri (string-append
1166 "http://download.gna.org/unrar/unrar-" version ".tar.gz"))
1167 (sha256
1168 (base32
1169 "1fgmjaxffj3shyxgy765jhxwz1cq88hk0fih1bsdzyvymyyz6mz7"))))
1170 (build-system gnu-build-system)
1171 (home-page "http://download.gna.org/unrar")
1172 (synopsis "RAR archive extraction tool")
1173 (description "Unrar is a simple command-line program to list and extract
1174RAR archives.")
1175 (license license:gpl2+)))