all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#36023] [PATCH] linux-boot: Fix e2fsck warning.
@ 2019-05-31 11:27 Danny Milosavljevic
  2019-06-01 13:13 ` Ludovic Courtès
  2019-06-03 16:17 ` [bug#36023] " Jonathan Brielmaier
  0 siblings, 2 replies; 6+ messages in thread
From: Danny Milosavljevic @ 2019-05-31 11:27 UTC (permalink / raw)
  To: 36023

* gnu/build/linux-boot.scm (boot-system): Fix e2fsck warning.
---
 gnu/build/linux-boot.scm | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/gnu/build/linux-boot.scm b/gnu/build/linux-boot.scm
index a35d18ad7c..03f2ea245c 100644
--- a/gnu/build/linux-boot.scm
+++ b/gnu/build/linux-boot.scm
@@ -517,6 +517,8 @@ upon error."
          (unless (pre-mount)
            (error "pre-mount actions failed")))
 
+       (setenv "EXT2FS_NO_MTAB_OK" "1")
+
        (if root
            ;; The "--root=SPEC" kernel command-line option always provides a
            ;; string, but the string can represent a device, a UUID, or a
@@ -533,6 +535,8 @@ upon error."
        (for-each mount-file-system
                  (remove root-mount-point? mounts))
 
+       (setenv "EXT2FS_NO_MTAB_OK" #f)
+
        (if to-load
            (begin
              (switch-root "/root")

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [bug#36023] [PATCH] linux-boot: Fix e2fsck warning.
  2019-05-31 11:27 [bug#36023] [PATCH] linux-boot: Fix e2fsck warning Danny Milosavljevic
@ 2019-06-01 13:13 ` Ludovic Courtès
  2019-06-03 16:09   ` bug#36023: " Danny Milosavljevic
  2019-06-03 16:17 ` [bug#36023] " Jonathan Brielmaier
  1 sibling, 1 reply; 6+ messages in thread
From: Ludovic Courtès @ 2019-06-01 13:13 UTC (permalink / raw)
  To: Danny Milosavljevic; +Cc: 36023

Danny Milosavljevic <dannym@scratchpost.org> skribis:

> * gnu/build/linux-boot.scm (boot-system): Fix e2fsck warning.

Oooh, thanks for fixing this one.  LGTM!

Ludo’.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#36023: [PATCH] linux-boot: Fix e2fsck warning.
  2019-06-01 13:13 ` Ludovic Courtès
@ 2019-06-03 16:09   ` Danny Milosavljevic
  0 siblings, 0 replies; 6+ messages in thread
From: Danny Milosavljevic @ 2019-06-03 16:09 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 36023-done

[-- Attachment #1: Type: text/plain, Size: 104 bytes --]

Thanks for the review!

Pushed it to guix master as commit aa901521e4e5625dd8a63e67a64be2f562ca61c7.

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [bug#36023] [PATCH] linux-boot: Fix e2fsck warning.
  2019-05-31 11:27 [bug#36023] [PATCH] linux-boot: Fix e2fsck warning Danny Milosavljevic
  2019-06-01 13:13 ` Ludovic Courtès
@ 2019-06-03 16:17 ` Jonathan Brielmaier
  2019-06-03 16:53   ` Danny Milosavljevic
  1 sibling, 1 reply; 6+ messages in thread
From: Jonathan Brielmaier @ 2019-06-03 16:17 UTC (permalink / raw)
  To: Danny Milosavljevic, 36023

On 5/31/19 1:27 PM, Danny Milosavljevic wrote:
> +       (setenv "EXT2FS_NO_MTAB_OK" "1")
> +
[...]
> +       (setenv "EXT2FS_NO_MTAB_OK" #f)
> +

Maybe it would be nice to have them constintly using either "0" and "1"
or #t and #f :)

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [bug#36023] [PATCH] linux-boot: Fix e2fsck warning.
  2019-06-03 16:17 ` [bug#36023] " Jonathan Brielmaier
@ 2019-06-03 16:53   ` Danny Milosavljevic
  2019-06-03 17:01     ` Jonathan Brielmaier
  0 siblings, 1 reply; 6+ messages in thread
From: Danny Milosavljevic @ 2019-06-03 16:53 UTC (permalink / raw)
  To: Jonathan Brielmaier; +Cc: 36023

[-- Attachment #1: Type: text/plain, Size: 880 bytes --]

Hi Jonathan,

On Mon, 3 Jun 2019 18:17:14 +0200
Jonathan Brielmaier <jonathan.brielmaier@web.de> wrote:

> On 5/31/19 1:27 PM, Danny Milosavljevic wrote:
> > +       (setenv "EXT2FS_NO_MTAB_OK" "1")
> > +  
> [...]
> > +       (setenv "EXT2FS_NO_MTAB_OK" #f)
> > +  
> 
> Maybe it would be nice to have them constintly using either "0" and "1"
> or #t and #f :)

Well, the UNIX environment interface and/or Guile's interface to it doesn't
work that way.  The UNIX environment is a string array.

e2fsck uses if(getenv("EXT2FS_NO_MTAB_OK")) to read the value of the entry
with the key "EXT2FS_NO_MTAB_OK".

So we can set the environment entry to any value we want and e2fsck's "if"
condition will evaluate to true.

And in order to remove it from the environment again, we call setenv with
#f.

We could also call unsetenv instead, I guess.  Should we?

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [bug#36023] [PATCH] linux-boot: Fix e2fsck warning.
  2019-06-03 16:53   ` Danny Milosavljevic
@ 2019-06-03 17:01     ` Jonathan Brielmaier
  0 siblings, 0 replies; 6+ messages in thread
From: Jonathan Brielmaier @ 2019-06-03 17:01 UTC (permalink / raw)
  To: Danny Milosavljevic; +Cc: 36023

On 6/3/19 6:53 PM, Danny Milosavljevic wrote:
> Hi Jonathan,
>
> On Mon, 3 Jun 2019 18:17:14 +0200
> Jonathan Brielmaier <jonathan.brielmaier@web.de> wrote:
>
>> On 5/31/19 1:27 PM, Danny Milosavljevic wrote:
>>> +       (setenv "EXT2FS_NO_MTAB_OK" "1")
>>> +
>> [...]
>>> +       (setenv "EXT2FS_NO_MTAB_OK" #f)
>>> +
>>
>> Maybe it would be nice to have them constintly using either "0" and "1"
>> or #t and #f :)
>
> Well, the UNIX environment interface and/or Guile's interface to it doesn't
> work that way.  The UNIX environment is a string array.
>
> e2fsck uses if(getenv("EXT2FS_NO_MTAB_OK")) to read the value of the entry
> with the key "EXT2FS_NO_MTAB_OK".
>
> So we can set the environment entry to any value we want and e2fsck's "if"
> condition will evaluate to true.
>
> And in order to remove it from the environment again, we call setenv with
> #f.
>
> We could also call unsetenv instead, I guess.  Should we?

Ah, oke. Thanks for the explanation. I think we can leave it as it is...

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-06-03 17:02 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-31 11:27 [bug#36023] [PATCH] linux-boot: Fix e2fsck warning Danny Milosavljevic
2019-06-01 13:13 ` Ludovic Courtès
2019-06-03 16:09   ` bug#36023: " Danny Milosavljevic
2019-06-03 16:17 ` [bug#36023] " Jonathan Brielmaier
2019-06-03 16:53   ` Danny Milosavljevic
2019-06-03 17:01     ` Jonathan Brielmaier

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.