about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--nix.conf.example8
-rw-r--r--src/libstore/build.cc9
2 files changed, 8 insertions, 9 deletions
diff --git a/nix.conf.example b/nix.conf.example
index a97554b18e73..547fa6cdc04e 100644
--- a/nix.conf.example
+++ b/nix.conf.example
@@ -164,13 +164,13 @@
 # (using `mount --bind' on Linux) some directories from the normal
 # file system hierarchy inside the chroot.  These are the Nix store,
 # the temporary build directory (usually /tmp/nix-<pid>-<number>) and
-# the directories listed here.  The default is "/dev /proc".  Files
-# in /dev (such as /dev/null) are needed by many builds, and some
-# files in /proc may also be needed occasionally.
+# the directories listed here.  The default is "/dev /dev/pts /proc".
+# Files in /dev (such as /dev/null) are needed by many builds, and
+# some files in /proc may also be needed occasionally.
 #
 # Example:
 #   build-use-chroot = /dev /proc /bin
-#build-chroot-dirs = /dev /proc
+#build-chroot-dirs = /dev /dev/pts /proc
 
 
 ### Option `system'
diff --git a/src/libstore/build.cc b/src/libstore/build.cc
index 586e44922197..3cd281fc839f 100644
--- a/src/libstore/build.cc
+++ b/src/libstore/build.cc
@@ -1744,15 +1744,14 @@ void DerivationGoal::startBuilder()
         autoDelChrootTmp = boost::shared_ptr<AutoDelete>(new AutoDelete(chrootTmpDir));
 
         /* Bind-mount a user-configurable set of directories from the
-           host file system. */
+           host file system.  The `/dev/pts' directory must be mounted
+           separately so that newly-created pseudo-terminals show
+           up. */
         Paths defaultDirs;
         defaultDirs.push_back("/dev");
-
-	/* The `/dev/pts' directory must be mounted separately so that
-	   newly-created pseudo-terminals show up.  */
         defaultDirs.push_back("/dev/pts");
-
         defaultDirs.push_back("/proc");
+        
         Paths dirsInChroot = querySetting("build-chroot-dirs", defaultDirs);
 
         dirsInChroot.push_front(nixStore);