From patchwork Wed Feb 26 20:41:47 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 20448 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 27BA727BBEA; Wed, 26 Feb 2020 20:42:14 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id DB24427BBE4 for ; Wed, 26 Feb 2020 20:42:13 +0000 (GMT) Received: from localhost ([::1]:49674 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j73VV-00011U-F1 for patchwork@mira.cbaines.net; Wed, 26 Feb 2020 15:42:13 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:38415) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j73VM-0000wf-64 for guix-patches@gnu.org; Wed, 26 Feb 2020 15:42:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j73VL-0005X3-0V for guix-patches@gnu.org; Wed, 26 Feb 2020 15:42:04 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:51781) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j73VK-0005VQ-Sf for guix-patches@gnu.org; Wed, 26 Feb 2020 15:42:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1j73VK-00068a-QY for guix-patches@gnu.org; Wed, 26 Feb 2020 15:42:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#39698] [PATCH] file-systems: Set default value of the check? field to #f for NFS Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 26 Feb 2020 20:42:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 39698 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Maxim Cournoyer Cc: 39698@debbugs.gnu.org Received: via spool by 39698-submit@debbugs.gnu.org id=B39698.158274972223584 (code B ref 39698); Wed, 26 Feb 2020 20:42:02 +0000 Received: (at 39698) by debbugs.gnu.org; 26 Feb 2020 20:42:02 +0000 Received: from localhost ([127.0.0.1]:57750 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j73VJ-000689-Ns for submit@debbugs.gnu.org; Wed, 26 Feb 2020 15:42:02 -0500 Received: from eggs.gnu.org ([209.51.188.92]:51423) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j73VH-00067m-24 for 39698@debbugs.gnu.org; Wed, 26 Feb 2020 15:42:00 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:50396) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j73VB-0004CP-PG; Wed, 26 Feb 2020 15:41:53 -0500 Received: from 128.pool80-103-133.dynamic.orange.es ([80.103.133.128]:42956 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1j73VA-00029Q-ST; Wed, 26 Feb 2020 15:41:53 -0500 From: Ludovic =?utf-8?q?Court=C3=A8s?= References: <87d0a9i3il.fsf@gmail.com> <87zhdayipo.fsf@gnu.org> <87v9nwklm6.fsf@gmail.com> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 8 =?utf-8?q?Vent=C3=B4se?= an 228 de la =?utf-8?q?R?= =?utf-8?q?=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Wed, 26 Feb 2020 21:41:47 +0100 In-Reply-To: <87v9nwklm6.fsf@gmail.com> (Maxim Cournoyer's message of "Mon, 24 Feb 2020 11:15:13 -0500") Message-ID: <878skpcc8k.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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 Hi Maxim, Maxim Cournoyer skribis: > From ca38de33a7a31c7b96f7e920038b2fb6352160a8 Mon Sep 17 00:00:00 2001 > From: Maxim Cournoyer > Date: Mon, 24 Feb 2020 11:08:42 -0500 > Subject: [PATCH] build: file-systems: Skip check for NFS file systems > > * gnu/build/file-systems.scm (mount-file-system): Do not call > `check-file-system' when the file system is of NFS type. > --- > gnu/build/file-systems.scm | 12 ++++++------ > 1 file changed, 6 insertions(+), 6 deletions(-) > > diff --git a/gnu/build/file-systems.scm b/gnu/build/file-systems.scm > index cfa3898f83..76c143654d 100644 > --- a/gnu/build/file-systems.scm > +++ b/gnu/build/file-systems.scm > @@ -5,6 +5,7 @@ > ;;; Copyright © 2019 Guillaume Le Vaillant > ;;; Copyright © 2019 Tobias Geerinckx-Rice > ;;; Copyright © 2019 David C. Trudgian > +;;; Copyright © 2020 Maxim Cournoyer > ;;; > ;;; This file is part of GNU Guix. > ;;; > @@ -663,6 +664,7 @@ corresponds to the symbols listed in FLAGS." > (string-append "," options) > ""))))) > (let* ((type (file-system-type fs)) > + (nfs? (string-prefix? "nfs" type)) > (fs-options (file-system-options fs)) > (options (if (null? fs-options) > #f > @@ -671,7 +673,7 @@ corresponds to the symbols listed in FLAGS." > (mount-point (string-append root "/" > (file-system-mount-point fs))) > (flags (mount-flags->bit-mask (file-system-flags fs)))) > - (when (file-system-check? fs) > + (when (and (file-system-check? fs) (not nfs?)) > (check-file-system source type)) Looking more closely, I see this: --8<---------------cut here---------------start------------->8--- (define (check-file-system device type) "Run a file system check of TYPE on DEVICE." (define check-procedure (cond ((string-prefix? "ext" type) check-ext2-file-system) ((string-prefix? "btrfs" type) check-btrfs-file-system) ((string-suffix? "fat" type) check-fat-file-system) ((string-prefix? "jfs" type) check-jfs-file-system) (else #f))) (if check-procedure … (format (current-error-port) "No file system check procedure for ~a; skipping~%" device))) --8<---------------cut here---------------end--------------->8--- Isn’t it already taking care of not attempting to check NFS? Or, to get rid of the warning, what about: ? Thanks, Ludo’. diff --git a/gnu/build/file-systems.scm b/gnu/build/file-systems.scm index ee6375515f..faf64ce304 100644 --- a/gnu/build/file-systems.scm +++ b/gnu/build/file-systems.scm @@ -581,6 +581,7 @@ were found." ((string-prefix? "btrfs" type) check-btrfs-file-system) ((string-suffix? "fat" type) check-fat-file-system) ((string-prefix? "jfs" type) check-jfs-file-system) + ((string-prefix? "nfs" type) (const 'pass)) (else #f))) (if check-procedure