diff mbox series

[bug#35888] gnu: Use make-linux-libre-headers.

Message ID OPa3fxaUGGnTWGGG-2rnIdYHu33Tcxn6QiLKB0CaoicQ5fG_Nkt3obhtAWL3v5SfQbU7KHkacGL3Nuw7eedjkmSqpFN7f-w9KcllciFISB0=@carldong.me
State Accepted
Headers show
Series [bug#35888] gnu: Use make-linux-libre-headers. | expand

Checks

Context Check Description
cbaines/applying patch fail Apply failed

Commit Message

Carl Dong May 24, 2019, 9:57 p.m. UTC
* gnu/packages/linux.scm (make-linux-libre-headers): New variable.
  (linux-libre): Rename and define as linux-libre-5.1.
  (linux-libre-headers): Rename and define as
  linux-libre-headers-4.14.67.
  (linux-libre-5.1, linux-libre-headers-4.14.67): Use
  make-linux-libre-headers.
  (linux-libre-5.1, linux-libre-headers-5.1, linux-libre-headers-4.19,
  %linux-libre-4.15-version, %linux-libre-4.15-hash, linux-libre-4.15,
  linux-libre-headers-4.15, linux-libre-headers-4.14): New variables.
---
 gnu/packages/linux.scm | 48 ++++++++++++++++++++++++++++++++++++------
 1 file changed, 41 insertions(+), 7 deletions(-)

Comments

Carl Dong May 24, 2019, 10:05 p.m. UTC | #1
To give a bit more context to this that I explained over IRC to rekado, 4.15 is
the lowest kernel version that is required for riscv64 support (which I have
locally but am upstreaming bit-by-bit). I tested make-linux-libre-headers with
the rest of the already declared kernel versions and they build fine, but feel
free to remove them :-)

Note that unlike my conversation with rekado, I am not bumping the default
linux-libre-headers here (see how it is -4.14.67 not just -4.14), just so this
can avoid triggering massive rebuilds.

Cheers,
Carl Dong
accounts@carldong.me
"I fight for the users"
Danny Milosavljevic May 29, 2019, 4:32 p.m. UTC | #2
Pushed to guix master as commit a15cee50cebddc665a16b455f44e22dcfb87d57f
with slight changes to the commit message.

Thanks!
diff mbox series

Patch

diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index b645249649..18e091a95a 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -169,18 +169,20 @@  defconfig.  Return the appropriate make target if applicable, otherwise return
          "mirror://gnu/linux-libre/" version "-gnu/linux-libre-"
          version "-gnu.tar.xz")))
 
-(define-public linux-libre-headers
+(define (make-linux-libre-headers version hash)
   (package
     (name "linux-libre-headers")
-    (version "4.14.67")
+    (version version)
     (source (origin
              (method url-fetch)
              (uri (linux-libre-urls version))
-             (sha256
-              (base32
-               "050zvdxjy6sc64q75pr1gxsmh49chwav2pwxz8xlif39bvahnrpg"))))
+             (sha256 (base32 hash))))
     (build-system gnu-build-system)
-    (native-inputs `(("perl" ,perl)))
+    (native-inputs `(("perl" ,perl)
+                     ,@(if (version>=? version "4.16")
+                           `(("flex" ,flex)
+                             ("bison" ,bison))
+                           '())))
     (arguments
      `(#:modules ((guix build gnu-build-system)
                   (guix build utils)
@@ -433,13 +435,17 @@  It has been modified to remove all non-free binary blobs.")
   (list %boot-logo-patch
         %linux-libre-arm-export-__sync_icache_dcache-patch))
 
-(define-public linux-libre
+(define-public linux-libre-5.1
   (make-linux-libre %linux-libre-version
                     %linux-libre-hash
                     '("x86_64-linux" "i686-linux" "armhf-linux" "aarch64-linux")
                     #:patches %linux-libre-5.1-patches
                     #:configuration-file kernel-config))
 
+(define-public linux-libre-headers-5.1
+  (make-linux-libre-headers %linux-libre-version
+                            %linux-libre-hash))
+
 (define %linux-libre-4.19-version "4.19.45")
 (define %linux-libre-4.19-hash "1wiy8vzpzzml4k76nv3ycjx7ky55x7dqx3mgpjqbh73mj2gcr5bx")
 
@@ -454,6 +460,23 @@  It has been modified to remove all non-free binary blobs.")
                     #:patches %linux-libre-4.19-patches
                     #:configuration-file kernel-config))
 
+(define-public linux-libre-headers-4.19
+  (make-linux-libre-headers %linux-libre-4.19-version
+                            %linux-libre-4.19-hash))
+
+(define %linux-libre-4.15-version "4.15.18")
+(define %linux-libre-4.15-hash "0f0s4drx888ydlwjcm9qcxqian4850yiv2vamyw9bbjf83frwxyw")
+
+(define-public linux-libre-4.15
+  (make-linux-libre %linux-libre-4.15-version
+                    %linux-libre-4.15-hash
+                    '("x86_64-linux" "i686-linux" "armhf-linux")
+                    #:configuration-file kernel-config))
+
+(define-public linux-libre-headers-4.15
+  (make-linux-libre-headers %linux-libre-4.15-version
+                            %linux-libre-4.15-hash))
+
 (define %linux-libre-4.14-version "4.14.121")
 (define %linux-libre-4.14-hash "1g7gyjmp056pasf9m34dqs8pa15my6hqasdd551jw8mgkbhsfnxg")
 
@@ -463,6 +486,10 @@  It has been modified to remove all non-free binary blobs.")
                     '("x86_64-linux" "i686-linux" "armhf-linux")
                     #:configuration-file kernel-config))
 
+(define-public linux-libre-headers-4.14
+  (make-linux-libre-headers %linux-libre-4.14-version
+                            %linux-libre-4.14-hash))
+
 (define-public linux-libre-4.9
   (make-linux-libre "4.9.178"
                     "1ridlkymf382qnkc6hi07pkghrrxfv2avx55snjnkfcpdccvsmrb"
@@ -481,6 +508,13 @@  It has been modified to remove all non-free binary blobs.")
                        ("CONFIG_DEVPTS_MULTIPLE_INSTANCES" . #t))
                      %default-extra-linux-options)))
 
+(define-public linux-libre-headers-4.14.67
+  (make-linux-libre-headers "4.14.67"
+                            "050zvdxjy6sc64q75pr1gxsmh49chwav2pwxz8xlif39bvahnrpg"))
+
+(define-public linux-libre-headers linux-libre-headers-4.14.67)
+(define-public linux-libre linux-libre-5.1)
+
 (define-public linux-libre-arm-generic
   (make-linux-libre %linux-libre-version
                     %linux-libre-hash