summaryrefslogtreecommitdiff
path: root/build-recipe-debootstrap
diff options
context:
space:
mode:
authorSjoerd Simons <sjoerd.simons@collabora.co.uk>2017-01-31 09:48:10 +0100
committerSjoerd Simons <sjoerd.simons@collabora.co.uk>2017-02-08 11:30:58 +0100
commit4cb54f6ed94cb2ad94007cd72aa1bc40f384f319 (patch)
tree2a27a9066af499f0f04bd7fd5425d7a11566d3d7 /build-recipe-debootstrap
parent08c4e3c12ace96779547ecd1130088d544cb023d (diff)
debootstrap: Mount virtual filesystems in the debootstrap root
For the debootstrap recipe the virtual filesystems also should be mounted in the actual build root not just the main one. Signed-off-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk>
Diffstat (limited to 'build-recipe-debootstrap')
-rw-r--r--build-recipe-debootstrap10
1 files changed, 10 insertions, 0 deletions
diff --git a/build-recipe-debootstrap b/build-recipe-debootstrap
index ae52dc0..5ae7cfc 100644
--- a/build-recipe-debootstrap
+++ b/build-recipe-debootstrap
@@ -65,12 +65,22 @@ recipe_build_debootstrap() {
cp $BUILD_ROOT/etc/hosts $BUILD_ROOT/$myroot/etc/hosts
fi
+ # Mount special filesystem in the debootstrap build root
+ mount -n -tproc none $BUILD_ROOT/$myroot/proc
+ mount -n -tdevpts -omode=0620,gid=5 none $BUILD_ROOT/$myroot/dev/pts
+ mkdir -p $BUILD_ROOT/$myroot/dev/shm
+ mount -n -ttmpfs none $BUILD_ROOT/$myroot/dev/shm
+
# move topdir over
mv "$BUILD_ROOT/$TOPDIR" "$BUILD_ROOT/$myroot/${TOPDIR%/*}"
# do the build
dsc_build "$BUILD_ROOT/$myroot"
+ umount -n $BUILD_ROOT/$myroot/proc
+ umount -n $BUILD_ROOT/$myroot/dev/pts
+ umount -n $BUILD_ROOT/$myroot/dev/shm
+
# move topdir back
mv "$BUILD_ROOT/$myroot/$TOPDIR" "$BUILD_ROOT/${TOPDIR%/*}"