aboutsummaryrefslogtreecommitdiff
path: root/gnu/compression.scm
blob: 0418e80a15879225a9f87915711213395e0ecafa (about) (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2022 Mathieu Othacehe <othacehe@gnu.org>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.

(define-module (gnu compression)
  #:use-module (guix gexp)
  #:use-module (guix ui)
  #:use-module ((gnu packages compression) #:hide (zip))
  #:use-module (srfi srfi-1)
  #:use-module (srfi srfi-9)
  #:use-module (ice-9 match)
  #:export (compressor
            compressor?
            compressor-name
            compressor-extension
            compressor-command
            %compressors
            lookup-compressor))

;; Type of a compression tool.
(define-record-type <compressor>
  (compressor name extension command)
  compressor?
  (name       compressor-name)      ;string (e.g., "gzip")
  (extension  compressor-extension) ;string (e.g., ".lz")
  (command    compressor-command))  ;gexp (e.g., #~(list "/gnu/store/…/gzip"
                                    ;                    "-9n" ))

(define %compressors
  ;; Available compression tools.
  (list (compressor "gzip"  ".gz"
                    #~(list #+(file-append gzip "/bin/gzip") "-9n"))
        (compressor "lzip"  ".lz"
                    #~(list #+(file-append lzip "/bin/lzip") "-9"))
        (compressor "xz"    ".xz"
                    #~(append (list #+(file-append xz "/bin/xz")
                                    "-e")
                              (%xz-parallel-args)))
        (compressor "bzip2" ".bz2"
                    #~(list #+(file-append bzip2 "/bin/bzip2") "-9"))
        (compressor "zstd" ".zst"
                    ;; The default level 3 compresses better than gzip in a
                    ;; fraction of the time, while the highest level 19
                    ;; (de)compresses more slowly and worse than xz.
                    #~(list #+(file-append zstd "/bin/zstd") "-3"))
        (compressor "none" "" #f)))

(define (lookup-compressor name)
  "Return the compressor object called NAME.  Error out if it could not be
found."
  (or (find (match-lambda
              (($ <compressor> name*)
               (string=? name* name)))
            %compressors)
      (leave (G_ "~a: compressor not found~%") name)))
2022-01-27gnu: soapyhackrf: Update to 0.3.4....* gnu/packages/radio.scm (soapyhackrf): Update to 0.3.4. Guillaume Le Vaillant 2022-01-27gnu: soapysdr: Update to 0.8.1....* gnu/packages/radio.scm (soapysdr): Update to 0.8.1. Guillaume Le Vaillant 2022-01-27gnu: flrig: Update to 1.4.04....* gnu/packages/radio.scm (flrig): Update to 1.4.04. [inputs]: Add eudev. Guillaume Le Vaillant 2022-01-27gnu: Add flmsg....* gnu/packages/radio.scm (flmsg): New variable. Guillaume Le Vaillant 2022-01-18gnu: gqrx: Update to 2.15.4....* gnu/packages/radio.scm (gqrx): Update to 2.15.4. Guillaume Le Vaillant 2021-12-17gnu: Remove unneeded uses of custom GCC versions....* gnu/packages/bioinformatics.scm (libmaus2, biobambam2)[native-inputs]: Remove GCC-10. * gnu/packages/game-development.scm (libresprite, python-pyxel)[native-inputs]: Likewise. * gnu/packages/lua.scm (emilua)[native-inputs]: Likewise. * gnu/packages/radio.scm (sdr++)[native-inputs]: Likewise. * gnu/packages/wm.scm (fnott)[native-inputs]: Likewise. * gnu/packages/text-editors.scm (kakoune)[native-inputs]: Likewise. (scintilla)[native-inputs]: Remove GCC-9. * gnu/packages/build-tools.scm (bear)[native-inputs]: Likewise. * gnu/packages/cpp.scm (magic-enum)[native-inputs]: Likewise. * gnu/packages/games.scm (openttd)[native-inputs]: Likewise. (schiffbruch)[native-inputs]: Remove GCC-11. * gnu/packages/music.scm (liquidsfz, geonkick)[native-inputs]: Remove GCC-9. * gnu/packages/fcitx5.scm (fcitx5, libime, fcitx5-configtool)[native-inputs]: Likewise. * gnu/packages/wine.scm (dxvk32)[native-inputs]: Likewise. * gnu/packages/ftp.scm (libfilezilla)[native-inputs]: Remove GCC-8. * gnu/packages/image.scm (blurhash)[native-inputs]: Likewise. * gnu/packages/jami.scm (libring)[native-inputs]: Likewise. * gnu/packages/pdf.scm (xournalpp)[native-inputs]: Likewise. * gnu/packages/telegram.scm (webrtc-for-telegram-desktop, telegram-desktop)[native-inputs]: Likewise. Marius Bakke 2021-12-17gnu: js8call: Remove workaround....* gnu/packages/radio.scm (js8call)[arguments]: Remove 'work-around-runtime-bug' phase. Guillaume Le Vaillant 2021-12-17gnu: wsjtx: Update to 2.5.2....* gnu/packages/radio.scm (wsjtx-hamlib, wsjtx): Update to 2.5.2. [arguments]: Remove 'work-around-runtime-bug' phase. Guillaume Le Vaillant 2021-12-17gnu: xnec2c: Update to 4.2....* gnu/packages/radio.scm (xnec2c): Update to 4.2. [arguments]: Remove 'fix-makefile' and 'fix-paths' phases. Guillaume Le Vaillant 2021-12-17gnu: dump1090: Update to 6.1....* gnu/packages/radio.scm (dump1090): Update to 6.1. Guillaume Le Vaillant 2021-12-17gnu: rtl-433: Update to 21.12....* gnu/packages/radio.scm (rtl-433): Update to 21.12. Guillaume Le Vaillant 2021-12-17gnu: qsstv: Update to 9.5.8....* gnu/packages/radio.scm (qsstv): Update to 9.5.8. [arguments]: Remove 'fix-newer-hamlib-support' phase. Guillaume Le Vaillant 2021-12-17gnu: dream: Update to 2.2....* gnu/packages/radio.scm (dream): Update to 2.2. Guillaume Le Vaillant 2021-12-17gnu: wfview: Update to 1.2d....* gnu/packages/radio.scm (wfview): Update to 1.2d. [inputs]: Add opus. [arguments]: Update 'configure' phase. Remove custom 'install' phase. Guillaume Le Vaillant 2021-12-17gnu: sdrangel: Update to 6.17.5....* gnu/packages/radio.scm (sdrangel): Update to 6.17.5. Guillaume Le Vaillant 2021-12-15gnu: gqrx: Update to 2.15....* gnu/packages/radio.scm (gqrx): Update to 2.15. [source]: Update source URI. Signed-off-by: Leo Famulari <leo@famulari.name> Nikolay Korotkiy 2021-12-13gnu: Further simplify package inputs....This is the result of running: ./pre-inst-env guix style --input-simplification=safe and manually undoing changes on a dozen of packages to reduce rebuilds (derivations for emacs, icecat, and libreoffice are unchanged.) Ludovic Courtès 2021-12-13gnu: Simplify package inputs....This commit was obtained by running: ./pre-inst-env guix style without any additional argument. Ludovic Courtès 2021-12-05Merge remote-tracking branch 'origin/master' into core-updates-frozenRicardo Wurmus 2021-12-01gnu: sdrangel: Add missing input....QtQuick is required by some runtime features. * gnu/packages/radio.scm (sdrangel)[inputs]: Add qtquickcontrols2. Guillaume Le Vaillant 2021-11-20gnu: sdrangel: Update to 6.17.3....* gnu/packages/radio.scm (sdrangel): Update to 6.17.3. [arguments]: Add 'fix-boost-compatibility' phase. Guillaume Le Vaillant 2021-10-31Merge remote-tracking branch 'origin/master' into core-updates-frozenEfraim Flashner 2021-10-25gnu: gnuradio: Disable a randomly failing test....* gnu/packages/radio.scm (gnuradio)[arguments]: Add qa_rotator_cc to the list of disabled tests. Guillaume Le Vaillant 2021-10-23gnu: sdr++: Activate M17 support....* gnu/packages/radio.scm (sdr++)[inputs]: Add codec2. [arguments]: Add "-DOPT_BUILD_M17_DECODER=ON" to 'configure-flags'. Guillaume Le Vaillant 2021-10-22gnu: hamlib: Update to 4.3.1....* gnu/packages/radio.scm (hamlib): Update to 4.3.1. Tobias Geerinckx-Rice 2021-10-22gnu: chirp: Update to 20211016....* gnu/packages/radio.scm (chirp): Update to 20211016. Tobias Geerinckx-Rice 2021-10-21gnu: flamp: Update to 2.2.07....* gnu/packages/radio.scm (flamp): Update to 2.2.07. Tobias Geerinckx-Rice 2021-10-18Merge remote-tracking branch 'signed/master' into core-updatesMathieu Othacehe 2021-10-18gnu: sdr++: Update to 1.0.4....* gnu/packages/radio.scm (sdr++): Update to 1.0.4. Guillaume Le Vaillant 2021-10-18gnu: sdrangel: Update to 6.17.1....* gnu/packages/radio.scm (sdrangel): Update to 6.17.1. Guillaume Le Vaillant