bug-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#22050: [PATCH v4 1/2] linux-boot: Add make-static-device-nodes.


From: Danny Milosavljevic
Subject: bug#22050: [PATCH v4 1/2] linux-boot: Add make-static-device-nodes.
Date: Fri, 15 Dec 2017 18:27:17 +0100

Hi Ludo,

On Fri, 15 Dec 2017 10:41:37 +0100
address@hidden (Ludovic Courtès) wrote:

> This looks good, but would it be enough to do:
> 
>   (mkdir-p (dirname (string-append "/dev/" name)))

mkdir permission needs to be specified to be #o755.

I've seen some variants in guix - but they are all buried somewhere deep:

./gnu/services/cups.scm:        (define (mkdir-p/perms directory owner perms)
./gnu/services/dns.scm:      (define (mkdir-p/perms directory owner perms)
./gnu/services/mail.scm:      (define (mkdir-p/perms directory owner perms)
./guix/build/utils.scm:(define (mkdir-p dir)
./guix/build/graft.scm:(define* (mkdir-p* dir #:optional (mode #o755))

I don't feel good relying on magical unspecified permissions in code required 
to boot the system.  I think mkdir-p itself subtracts the umask or something.  
Is the umask guaranteed to be 0 at the point of usage of 
make-static-device-nodes ?






reply via email to

[Prev in Thread] Current Thread [Next in Thread]