summaryrefslogtreecommitdiff
path: root/gnu/build
diff options
context:
space:
mode:
authorOleg Pykhalov <go.wigust@gmail.com>2022-07-19 19:40:28 +0300
committerOleg Pykhalov <go.wigust@gmail.com>2022-08-10 07:12:25 +0300
commit4b494878380920c8c7eecccd1f299164dd4a2c3f (patch)
tree04c7bb62fd257570ce6a5fb2a28f2a9b38811139 /gnu/build
parent97cb43e732a38758c95b7caf3963507188d011cf (diff)
gnu: system: file-systems: Add shared flag.
* gnu/build/file-systems.scm (mount-flags->bit-mask, mount-file-system): Handle shared flag. * gnu/system/file-systems.scm (invalid-file-system-flags): Add shared to known flags. * guix/build/syscalls.scm (MS_SHARED): New variable. * doc/guix.texi (File Systems): Document shared flag.
Diffstat (limited to 'gnu/build')
-rw-r--r--gnu/build/file-systems.scm6
1 files changed, 6 insertions, 0 deletions
diff --git a/gnu/build/file-systems.scm b/gnu/build/file-systems.scm
index 1d3b33e7bd..b9d46c9350 100644
--- a/gnu/build/file-systems.scm
+++ b/gnu/build/file-systems.scm
@@ -6,6 +6,7 @@
;;; Copyright © 2019–2021 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2019 David C. Trudgian <dave@trudgian.net>
;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
+;;; Copyright © 2022 Oleg Pykhalov <go.wigust@gmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -1123,6 +1124,8 @@ corresponds to the symbols listed in FLAGS."
(logior MS_STRICTATIME (loop rest)))
(('lazy-time rest ...)
(logior MS_LAZYTIME (loop rest)))
+ (('shared rest ...)
+ (loop rest))
(()
0))))
@@ -1186,6 +1189,9 @@ corresponds to the symbols listed in FLAGS."
(cond
((string-prefix? "nfs" type)
(mount-nfs source target type flags options))
+ ((memq 'shared (file-system-flags fs))
+ (mount source target type flags options)
+ (mount "none" target #f MS_SHARED))
(else
(mount source target type flags options)))