gnu: freefall: Return #t from all phases.
[jackhill/guix/guix.git] / gnu / packages / linux.scm
index c02084f..7efe7fa 100644 (file)
@@ -19,7 +19,7 @@
 ;;; Copyright © 2016 Rene Saavedra <rennes@openmailbox.org>
 ;;; Copyright © 2016 Carlos Sánchez de La Lama <csanchezdll@gmail.com>
 ;;; Copyright © 2016, 2017 Nils Gillmann <ng0@n0.is>
-;;; Copyright © 2017 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2017, 2018 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2017 José Miguel Sánchez García <jmi2k@openmailbox.com>
 ;;; Copyright © 2017 Gábor Boskovits <boskovits@gmail.com>
 ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
@@ -284,6 +284,9 @@ for ARCH and optionally VARIANT, or #f if there is no such configuration."
        ("bc" ,bc)
        ("openssl" ,openssl)
        ("kmod" ,kmod)
+       ("elfutils" ,elfutils)  ; Needed to enable CONFIG_STACK_VALIDATION
+       ("flex" ,flex)
+       ("bison" ,bison)
        ;; On x86, build with GCC-7 for full retpoline support.
        ;; FIXME: Remove this when our default compiler has retpoline support.
        ,@(match (system->linux-architecture
@@ -308,6 +311,11 @@ for ARCH and optionally VARIANT, or #f if there is no such configuration."
                   (ice-9 match))
        #:phases
        (modify-phases %standard-phases
+         (add-after 'unpack 'patch-/bin/pwd
+           (lambda _
+             (substitute* (find-files "." "^Makefile(\\.include)?$")
+               (("/bin/pwd") "pwd"))
+             #t))
          (replace 'configure
            (lambda* (#:key inputs native-inputs target #:allow-other-keys)
              ;; Avoid introducing timestamps
@@ -383,8 +391,8 @@ It has been modified to remove all non-free binary blobs.")
 ;; supports qemu "virt" machine and possibly a large number of ARM boards.
 ;; See : https://wiki.debian.org/DebianKernel/ARMMP.
 
-(define %linux-libre-version "4.15.11")
-(define %linux-libre-hash "0nrsmw7x5nsc3906dfvfakkibv8pv09r1sf5ckzbkcbkwpyq62h8")
+(define %linux-libre-version "4.16.1")
+(define %linux-libre-hash "1zqbg7ivf79nzw0lw18bbld2wq16880k83526bwqh1nsydayp6k0")
 
 (define-public linux-libre
   (make-linux-libre %linux-libre-version
@@ -392,8 +400,8 @@ It has been modified to remove all non-free binary blobs.")
                     %linux-compatible-systems
                     #:configuration-file kernel-config))
 
-(define %linux-libre-4.14-version "4.14.28")
-(define %linux-libre-4.14-hash "0xg3zsm1yjsvxir8sz7zliz8gcc8d45xh23qyiszl75cfqjl36l3")
+(define %linux-libre-4.14-version "4.14.33")
+(define %linux-libre-4.14-hash "0ps9whsxc20gw5ags18rgkwgy6fzg66by70g8xjds7nijpzgl69m")
 
 (define-public linux-libre-4.14
   (make-linux-libre %linux-libre-4.14-version
@@ -402,20 +410,20 @@ It has been modified to remove all non-free binary blobs.")
                     #:configuration-file kernel-config))
 
 (define-public linux-libre-4.9
-  (make-linux-libre "4.9.88"
-                    "0qlhd8xw3g00i7krpfndkwxzjszk067h26qsxxsszvxyx2s6gp4x"
+  (make-linux-libre "4.9.93"
+                    "0flmsh4xy7ymyzwm8y4x4id798mx6vy3d6ala7x1bq41hf00075p"
                     %intel-compatible-systems
                     #:configuration-file kernel-config))
 
 (define-public linux-libre-4.4
-  (make-linux-libre "4.4.122"
-                    "1ayilv7474vsif3jpb723jbcy4kymv1fpdr96c1g743bad1wkqqq"
+  (make-linux-libre "4.4.127"
+                    "1av536sp6ancx0fy71wpmqv4r66pksrcjbnrcjggard6im4c8pjy"
                     %intel-compatible-systems
                     #:configuration-file kernel-config))
 
 (define-public linux-libre-4.1
-  (make-linux-libre "4.1.50"
-                    "1hl1pk724v2waa55bhxfmxyz9nl6pkcj4dc3l80jfvqdfgr55mm2"
+  (make-linux-libre "4.1.51"
+                    "0l8lpwjpckp44hjyx5qrxqdwwi97gyyc1n6pmk66cr3fpdhnk540"
                     %intel-compatible-systems
                     #:configuration-file kernel-config))
 
@@ -547,7 +555,7 @@ providing the system administrator with some help in common tasks.")
 (define-public util-linux
   (package
     (name "util-linux")
-    (version "2.31.1")
+    (version "2.32")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://kernel.org/linux/utils/"
@@ -555,9 +563,8 @@ providing the system administrator with some help in common tasks.")
                                   name "-" version ".tar.xz"))
               (sha256
                (base32
-                "04fzrnrr3pvqskvjn9f81y0knh0jvvqx4lmbz5pd4lfdm5pv2l8s"))
-              (patches (search-patches "util-linux-tests.patch"
-                                       "util-linux-CVE-2018-7738.patch"))
+                "0d2758kjll5xqm5fpp3sww1h66aahx161sf2b60jxqv4qymrfwvc"))
+              (patches (search-patches "util-linux-tests.patch"))
               (modules '((guix build utils)))
               (snippet
                ;; We take 'nologin' from Shadow, the 'logger' program from
@@ -790,18 +797,18 @@ slabtop, and skill.")
              (lambda* (#:key outputs #:allow-other-keys)
                (let* ((out (assoc-ref outputs "out"))
                       (lib (string-append out "/lib")))
-                 (and (zero? (system* "make" "install-libs"))
-
-                      ;; Make the .a writable so that 'strip' works.
-                      ;; Failing to do that, due to debug symbols, we
-                      ;; retain a reference to the final
-                      ;; linux-libre-headers, which refer to the
-                      ;; bootstrap binaries.
-                      (let ((archives (find-files lib "\\.a$")))
-                        (for-each (lambda (file)
-                                    (chmod file #o666))
-                                  archives)
-                        #t))))))))
+                 (invoke "make" "install-libs")
+
+                 ;; Make the .a writable so that 'strip' works.
+                 ;; Failing to do that, due to debug symbols, we
+                 ;; retain a reference to the final
+                 ;; linux-libre-headers, which refer to the
+                 ;; bootstrap binaries.
+                 (let ((archives (find-files lib "\\.a$")))
+                   (for-each (lambda (file)
+                               (chmod file #o666))
+                             archives))
+                 #t))))))
     (home-page "http://e2fsprogs.sourceforge.net/")
     (synopsis "Creating and checking ext2/ext3/ext4 file systems")
     (description
@@ -844,7 +851,8 @@ slabtop, and skill.")
            (with-directory-excursion bin
              (copy-file e2fsck "e2fsck")
              (remove-store-references "e2fsck")
-             (chmod "e2fsck" #o555))))))
+             (chmod "e2fsck" #o555))
+           #t))))
     (home-page (package-home-page e2fsprogs))
     (synopsis "Statically-linked e2fsck command from e2fsprogs")
     (description "This package provides statically-linked e2fsck command taken
@@ -910,14 +918,15 @@ Zerofree requires the file system to be unmounted or mounted read-only.")
 (define-public strace
   (package
     (name "strace")
-    (version "4.21")
+    (version "4.22")
+    (home-page "https://strace.io")
     (source (origin
              (method url-fetch)
-             (uri (string-append "https://github.com/strace/strace/releases/"
-                                 "download/v" version "/strace-" version ".tar.xz"))
+             (uri (string-append home-page "/files/" version
+                                 "/strace-" version ".tar.xz"))
              (sha256
               (base32
-               "0dsw6xcfrmygidp1dj2ch8cl8icrar7789snkb2r8gh78kdqhxjw"))))
+               "17dkpnsjxmys1ydidm9wcvc3wscsz44fmlxw3dclspn9cj9d1306"))))
     (build-system gnu-build-system)
     (arguments
      '(#:phases
@@ -928,7 +937,6 @@ Zerofree requires the file system to be unmounted or mounted read-only.")
                (("/bin/sh") (which "sh")))
              #t)))))
     (native-inputs `(("perl" ,perl)))
-    (home-page "https://strace.io/")
     (synopsis "System call tracer for Linux")
     (description
      "strace is a system call tracer, i.e. a debugging tool which prints out a
@@ -1122,8 +1130,7 @@ configure the Linux 2.4.x and later IPv4 packet filtering ruleset
 This package also includes @command{ip6tables}, which is used to configure the
 IPv6 packet filter.
 
-Both commands are targeted at system administrators.
-")
+Both commands are targeted at system administrators.")
     (license license:gpl2+)))
 
 (define-public ebtables
@@ -1184,7 +1191,7 @@ that the Ethernet protocol is much simpler than the IP protocol.")
 (define-public iproute
   (package
     (name "iproute2")
-    (version "4.15.0")
+    (version "4.16.0")
     (source (origin
               (method url-fetch)
               (uri (string-append
@@ -1192,7 +1199,7 @@ that the Ethernet protocol is much simpler than the IP protocol.")
                     version ".tar.xz"))
               (sha256
                (base32
-                "0mc3g4kj7h3jhwz2b2gdf41gp6bhqn7axh4mnyvhkdnpk5m63m28"))))
+                "02pfalg319jpbjz273ph725br8dnkzpfvi98azi9yd6p1w128p0c"))))
     (build-system gnu-build-system)
     (arguments
      `(#:tests? #f                                ; no test suite
@@ -2190,6 +2197,11 @@ interface.")
     (arguments
      '(#:phases (modify-phases %standard-phases
                   (delete 'configure)
+                  (add-after 'unpack 'gzip-determinism
+                    (lambda _
+                      (substitute* "Makefile"
+                        (("gzip") "gzip --no-name"))
+                      #t))
                   (add-before
                    'build 'no-werror-no-ldconfig
                    (lambda _
@@ -3121,10 +3133,9 @@ write access to exFAT devices.")
                       ;; need to bootstrap things ourselves.
                       (substitute* "autogen.sh"
                         (("/bin/sh") (which "sh")))
-                      (and (zero? (system* "./autogen.sh"))
-                           (begin
-                             (patch-makefile-SHELL "Makefile.include.in")
-                             #t)))))
+                      (invoke "./autogen.sh")
+                      (patch-makefile-SHELL "Makefile.include.in")
+                      #t)))
 
        ;; Make sure programs find libgpm.so.
        #:configure-flags (list (string-append "LDFLAGS=-Wl,-rpath="
@@ -3148,7 +3159,7 @@ and copy/paste text in the console and in xterm.")
 (define-public btrfs-progs
   (package
     (name "btrfs-progs")
-    (version "4.14.1")
+    (version "4.15.1")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://kernel.org/linux/kernel/"
@@ -3156,14 +3167,15 @@ and copy/paste text in the console and in xterm.")
                                   "btrfs-progs-v" version ".tar.xz"))
               (sha256
                (base32
-                "1palnddw3d50kyflwk1j4xapbc6jniid6j5i9dsr8l8a7nkv7ich"))))
+                "15izak6jg6pqr6ha9447cdrdj9k6kfiarvwlrj53cpvrsv02l437"))
+              (patches (search-patches "btrfs-progs-e-value-block.patch"))))
     (build-system gnu-build-system)
     (outputs '("out"
                "static"))      ; static versions of the binaries in "out"
     (arguments
      '(#:phases (modify-phases %standard-phases
                  (add-after 'build 'build-static
-                   (lambda _ (zero? (system* "make" "static"))))
+                   (lambda _ (invoke "make" "static")))
                  (add-after 'install 'install-bash-completion
                    (lambda* (#:key outputs #:allow-other-keys)
                      (let* ((out (assoc-ref outputs "out"))
@@ -3176,9 +3188,9 @@ and copy/paste text in the console and in xterm.")
                    (let ((staticbin (string-append (assoc-ref %outputs "static")
                                                   "/bin")))
                      (lambda _
-                       (zero? (system* "make"
-                                       (string-append "bindir=" staticbin)
-                                       "install-static"))))))
+                       (invoke "make"
+                               (string-append "bindir=" staticbin)
+                               "install-static")))))
        #:test-target "test"
        #:parallel-tests? #f)) ; tests fail when run in parallel
     (inputs `(("e2fsprogs" ,e2fsprogs)
@@ -3197,7 +3209,9 @@ and copy/paste text in the console and in xterm.")
                      ("docbook-xsl" ,docbook-xsl)
                      ;; For tests.
                      ("acl" ,acl)
-                     ("which" ,which)))
+                     ("which" ,which)
+                     ;; The tests need 'grep' with perl regexp support.
+                     ("grep" ,grep)))
     (home-page "https://btrfs.wiki.kernel.org/")
     (synopsis "Create and manage btrfs copy-on-write file systems")
     (description "Btrfs is a @dfn{copy-on-write} (CoW) file system for Linux
@@ -3230,7 +3244,8 @@ repair and easy administration.")
            (mkdir-p (dirname target))
            (copy-file source target)
            (remove-store-references target)
-           (chmod target #o555)))))
+           (chmod target #o555)
+           #t))))
     (home-page (package-home-page btrfs-progs))
     (synopsis "Statically-linked btrfs command from btrfs-progs")
     (description "This package provides the statically-linked @command{btrfs}
@@ -3277,14 +3292,16 @@ disks and SD cards.  This package provides the userland utilities.")
      '(#:phases (modify-phases %standard-phases
                   (add-after 'unpack 'enter-subdirectory
                     (lambda _
-                      (chdir "tools/laptop/freefall")))
+                      (chdir "tools/laptop/freefall")
+                      #t))
                   (delete 'configure)
                   (add-before 'build 'increase-timeout
                     (lambda _
                       ;; The default of 2 seconds is too low: it assumes an
                       ;; open lid and AC power without actually checking.
                       (substitute* "freefall.c"
-                        (("alarm\\(2\\)") "alarm(5)")))))
+                        (("alarm\\(2\\)") "alarm(5)"))
+                      #t)))
        #:make-flags (list (string-append "PREFIX="
                                          (assoc-ref %outputs "out")))
        #:tests? #f)) ;no tests
@@ -3755,7 +3772,7 @@ developers.")
 (define-public radeontop
   (package
     (name "radeontop")
-    (version "1.0")
+    (version "1.1")
     (home-page "https://github.com/clbr/radeontop/")
     (source (origin
               (method url-fetch)
@@ -3763,7 +3780,7 @@ developers.")
               (file-name (string-append name "-" version ".tar.gz"))
               (sha256
                (base32
-                "1z38nibirqxrbsfyhfcrnzlcw16cqjp4ds6qnjfxalwayf9fm5x9"))))
+                "1fv06j5c99imvzkac3j40lgjhr5b2i77fnyffhlvj92bli1fm1c6"))))
     (build-system gnu-build-system)
     (arguments
      `(#:phases (modify-phases %standard-phases
@@ -4549,3 +4566,30 @@ text-mode or graphical applications that don't use a display server.
 Also included is @command{fbgrab}, a wrapper around @command{fbcat} that
 emulates the behaviour of Gunnar Monell's older fbgrab utility.")
     (license license:gpl2)))
+
+(define-public libcgroup
+  (package
+    (name "libcgroup")
+    (version "0.41")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append
+             "mirror://sourceforge/libcg/" name "/"
+             version "/" name "-" version ".tar.bz2"))
+       (sha256
+        (base32 "0lgvyq37gq84sk30sg18admxaj0j0p5dq3bl6g74a1ppgvf8pqz4"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:tests? #f))
+    (native-inputs
+     `(("bison" ,bison)
+       ("flex" ,flex)))
+    (inputs
+     `(("linux-pam" ,linux-pam)))
+    (home-page "https://sourceforge.net/projects/libcg/")
+    (synopsis "Control groups management tools")
+    (description "Control groups is Linux kernel method for process resource
+restriction, permission handling and more.  This package provides userspace
+interface to this kernel feature.")
+    (license license:lgpl2.1)))