From patchwork Tue Apr 2 19:28:53 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Danny Milosavljevic X-Patchwork-Id: 3182 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 4C46516E16; Tue, 2 Apr 2019 20:30:10 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.0 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id CDFCA16E13 for ; Tue, 2 Apr 2019 20:30:09 +0100 (BST) Received: from localhost ([127.0.0.1]:47061 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hBP6n-0005Jc-CM for patchwork@mira.cbaines.net; Tue, 02 Apr 2019 15:30:09 -0400 Received: from eggs.gnu.org ([209.51.188.92]:51608) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hBP6k-0005J9-F6 for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hBP6i-00052B-N7 for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:06 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:56431) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hBP6h-00051d-Jn for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hBP6h-0003FC-Fr for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#35110] [PATCH 1/3] gnu: Add make-linux-module. Resent-From: Danny Milosavljevic Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 02 Apr 2019 19:30:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35110 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 35110@debbugs.gnu.org Received: via spool by 35110-submit@debbugs.gnu.org id=B35110.155423334512340 (code B ref 35110); Tue, 02 Apr 2019 19:30:03 +0000 Received: (at 35110) by debbugs.gnu.org; 2 Apr 2019 19:29:05 +0000 Received: from localhost ([127.0.0.1]:41737 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hBP5l-0003Cx-7g for submit@debbugs.gnu.org; Tue, 02 Apr 2019 15:29:05 -0400 Received: from dd26836.kasserver.com ([85.13.145.193]:37524) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hBP5j-0003Cn-LB for 35110@debbugs.gnu.org; Tue, 02 Apr 2019 15:29:04 -0400 Received: from dayas.3.home (178.113.188.65.wireless.dyn.drei.com [178.113.188.65]) by dd26836.kasserver.com (Postfix) with ESMTPSA id 7A3D5336048F; Tue, 2 Apr 2019 21:29:02 +0200 (CEST) From: Danny Milosavljevic Date: Tue, 2 Apr 2019 21:28:53 +0200 Message-Id: <20190402192855.5314-1-dannym@scratchpost.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190402192729.5262-1-dannym@scratchpost.org> References: <20190402192729.5262-1-dannym@scratchpost.org> MIME-Version: 1.0 Tags: patch X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/linux.scm (make-linux-module): New procedure. --- gnu/packages/linux.scm | 66 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 9e4261eb02..55a314258f 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -415,6 +415,72 @@ for ARCH and optionally VARIANT, or #f if there is no such configuration." It has been modified to remove all non-free binary blobs.") (license license:gpl2))) +;; FIXME: Remove CONFIG_MODULE_SRCVERSION_ALL=y from our configs. +(define (make-linux-module linux module) + "Given a LINUX package and a MODULE package, build MODULE using LINUX." + (let ((linux-source + (package + (inherit linux) + (name "linux-source") + (arguments + (substitute-keyword-arguments (package-arguments linux) + ((#:phases phases) + `(modify-phases ,phases + (replace 'build + (lambda _ + (invoke "make" "modules_prepare"))) + (delete 'strip) ; faster. + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (out-lib-build (string-append out "/lib/modules/build"))) + ; TODO: Only preserve the minimum, i.e. [Kbuild], Kconfig, scripts, include, ".config". + (copy-recursively "." out-lib-build) + #t)))))))))) + (package + (inherit module) + (name (string-append (package-name module) "-" (package-name linux))) + (native-inputs + `(("linux-source" ,linux-source) + ("kmod" ,kmod) + ;("elfutils" ,elfutils) ; Needed to enable CONFIG_STACK_VALIDATION + ("gcc" ,gcc-7) + ,@(package-native-inputs module))) + (arguments + (substitute-keyword-arguments + (default-keyword-arguments (package-arguments module) + `(#:phases #f + #:make-flags '())) + ((#:phases phases) + `(modify-phases ,phases + (replace 'build + (lambda* (#:key inputs make-flags #:allow-other-keys) + (apply invoke "make" "-C" + (string-append (assoc-ref inputs "linux-source") + "/lib/modules/build") + (string-append "M=" (getcwd)) + make-flags))) + ;; This block was copied from make-linux-libre--only took the + ;; "modules_install" part. + (replace 'install + (lambda* (#:key inputs native-inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (moddir (string-append out "/lib/modules")) + (kmod (assoc-ref (or native-inputs inputs) "kmod"))) + ;; Install kernel modules + (mkdir-p moddir) + (invoke "make" + "-C" + (string-append (assoc-ref inputs "linux-source") + "/lib/modules/build") + (string-append "M=" (getcwd)) + (string-append "DEPMOD=" kmod "/bin/depmod") + (string-append "MODULE_DIR=" moddir) + (string-append "INSTALL_PATH=" out) + (string-append "INSTALL_MOD_PATH=" out) + "INSTALL_MOD_STRIP=1" + "modules_install"))))))))))) + (define %linux-libre-version "5.0.5") (define %linux-libre-hash "1yivxqprxfzhzid4qv9hpnb5i38kijrj2g2pyzz7niliya1c58li") From patchwork Tue Apr 2 19:28:54 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Danny Milosavljevic X-Patchwork-Id: 3184 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 6E12616E16; Tue, 2 Apr 2019 20:30:17 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id E81C716E13 for ; Tue, 2 Apr 2019 20:30:16 +0100 (BST) Received: from localhost ([127.0.0.1]:47109 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hBP6u-0005Sy-F3 for patchwork@mira.cbaines.net; Tue, 02 Apr 2019 15:30:16 -0400 Received: from eggs.gnu.org ([209.51.188.92]:51626) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hBP6l-0005JD-26 for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hBP6i-00052G-NT for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:07 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:56432) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hBP6i-00051w-CN for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hBP6i-0003FL-72 for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#35110] [PATCH 2/3] gnu: Add vhba-module-linux-libre. Resent-From: Danny Milosavljevic Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 02 Apr 2019 19:30:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35110 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 35110@debbugs.gnu.org Received: via spool by 35110-submit@debbugs.gnu.org id=B35110.155423334812365 (code B ref 35110); Tue, 02 Apr 2019 19:30:04 +0000 Received: (at 35110) by debbugs.gnu.org; 2 Apr 2019 19:29:08 +0000 Received: from localhost ([127.0.0.1]:41740 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hBP5n-0003DL-J8 for submit@debbugs.gnu.org; Tue, 02 Apr 2019 15:29:07 -0400 Received: from dd26836.kasserver.com ([85.13.145.193]:37532) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hBP5k-0003Cv-QC for 35110@debbugs.gnu.org; Tue, 02 Apr 2019 15:29:05 -0400 Received: from dayas.3.home (178.113.188.65.wireless.dyn.drei.com [178.113.188.65]) by dd26836.kasserver.com (Postfix) with ESMTPSA id D95E33363496; Tue, 2 Apr 2019 21:29:03 +0200 (CEST) From: Danny Milosavljevic Date: Tue, 2 Apr 2019 21:28:54 +0200 Message-Id: <20190402192855.5314-2-dannym@scratchpost.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190402192855.5314-1-dannym@scratchpost.org> References: <20190402192729.5262-1-dannym@scratchpost.org> <20190402192855.5314-1-dannym@scratchpost.org> MIME-Version: 1.0 Tags: patch X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Pierre Neidhardt Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches From: Pierre Neidhardt * gnu/packages/linux.scm (vhba-module): New variable. (vhba-module-linux-libre): New variable. Export it. Signed-off-by: Danny Milosavljevic --- gnu/packages/linux.scm | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 55a314258f..a2adb9b13d 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -495,6 +495,34 @@ It has been modified to remove all non-free binary blobs.") #:patches %linux-libre-5.0-patches #:configuration-file kernel-config)) +(define vhba-module + (package + (name "vhba-module") + (version "20170610") + (source (origin + (method url-fetch) + (uri (string-append + "http://downloads.sourceforge.net/cdemu/vhba-module-" + version ".tar.bz2")) + (sha256 + (base32 + "1v6r0bgx0a65vlh36b1l2965xybngbpga6rp54k4z74xk0zwjw3r")))) + (build-system gnu-build-system) + (arguments + ;; TODO: No tests? + `(#:tests? #f + #:phases + (modify-phases %standard-phases + (delete 'configure)))) + (home-page "https://cdemu.sourceforge.io/") + (synopsis "Kernel module that emulates SCSI devices") + (description "VHBA module provides a Virtual (SCSI) HBA, which is the link +between the CDemu userspace daemon and linux kernel.") + (license license:gpl2+))) + +(define-public vhba-module-linux-libre + (make-linux-module linux-libre vhba-module)) + (define %linux-libre-4.19-version "4.19.32") (define %linux-libre-4.19-hash "19bryl8nmnnnrfh91pc8q9yiayh5ca2nb6b32qyx6riahc5dy0i9") From patchwork Tue Apr 2 19:28:55 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Danny Milosavljevic X-Patchwork-Id: 3183 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id D20B016E16; Tue, 2 Apr 2019 20:30:10 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.0 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id 8A41416E13 for ; Tue, 2 Apr 2019 20:30:10 +0100 (BST) Received: from localhost ([127.0.0.1]:47069 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hBP6o-0005Jw-5N for patchwork@mira.cbaines.net; Tue, 02 Apr 2019 15:30:10 -0400 Received: from eggs.gnu.org ([209.51.188.92]:51641) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hBP6l-0005JI-GU for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hBP6k-000537-IU for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:07 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:56434) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hBP6j-00052V-Jw for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:06 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hBP6i-0003FT-Sv for guix-patches@gnu.org; Tue, 02 Apr 2019 15:30:05 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#35110] [PATCH 3/3] gnu: linux-libre: Disable module versioning. Resent-From: Danny Milosavljevic Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 02 Apr 2019 19:30:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35110 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 35110@debbugs.gnu.org Received: via spool by 35110-submit@debbugs.gnu.org id=B35110.155423334812372 (code B ref 35110); Tue, 02 Apr 2019 19:30:04 +0000 Received: (at 35110) by debbugs.gnu.org; 2 Apr 2019 19:29:08 +0000 Received: from localhost ([127.0.0.1]:41742 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hBP5o-0003DO-0C for submit@debbugs.gnu.org; Tue, 02 Apr 2019 15:29:08 -0400 Received: from dd26836.kasserver.com ([85.13.145.193]:37546) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hBP5l-0003D4-Vn for 35110@debbugs.gnu.org; Tue, 02 Apr 2019 15:29:06 -0400 Received: from dayas.3.home (178.113.188.65.wireless.dyn.drei.com [178.113.188.65]) by dd26836.kasserver.com (Postfix) with ESMTPSA id 1AF22336048F; Tue, 2 Apr 2019 21:29:05 +0200 (CEST) From: Danny Milosavljevic Date: Tue, 2 Apr 2019 21:28:55 +0200 Message-Id: <20190402192855.5314-3-dannym@scratchpost.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190402192855.5314-1-dannym@scratchpost.org> References: <20190402192729.5262-1-dannym@scratchpost.org> <20190402192855.5314-1-dannym@scratchpost.org> MIME-Version: 1.0 Tags: patch X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/aux-files/linux-libre/5.0-x86_64.conf: Remove CONFIG_MODULE_SRCVERSION_ALL. --- gnu/packages/aux-files/linux-libre/5.0-x86_64.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/aux-files/linux-libre/5.0-x86_64.conf b/gnu/packages/aux-files/linux-libre/5.0-x86_64.conf index 9e1a7eff0e..193413110f 100644 --- a/gnu/packages/aux-files/linux-libre/5.0-x86_64.conf +++ b/gnu/packages/aux-files/linux-libre/5.0-x86_64.conf @@ -794,7 +794,7 @@ CONFIG_MODULES=y CONFIG_MODULE_UNLOAD=y # CONFIG_MODULE_FORCE_UNLOAD is not set CONFIG_MODVERSIONS=y -CONFIG_MODULE_SRCVERSION_ALL=y +# CONFIG_MODULE_SRCVERSION_ALL is not set # CONFIG_MODULE_SIG is not set # CONFIG_MODULE_COMPRESS is not set CONFIG_MODULES_TREE_LOOKUP=y