From 0a58fd0c01586332e905428110df2365eb6ddc67 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Sat, 12 Dec 2015 10:12:33 +0100 Subject: [PATCH] Revert "xbps-src: fix uchroot chroot-style to not overwrite XBPS_CHROOT_CMD_ARGS." This reverts commit ba4bba203118a1b90bb239eeedbaf89a7fed8c0f. --- common/chroot-style/uchroot.sh | 5 +---- xbps-src | 9 +++++++++ 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/common/chroot-style/uchroot.sh b/common/chroot-style/uchroot.sh index 237db4ce9f1..395f9a64903 100755 --- a/common/chroot-style/uchroot.sh +++ b/common/chroot-style/uchroot.sh @@ -2,13 +2,10 @@ # # This chroot script uses xbps-uchroot(8). # -if [ -n "$XBPS_TEMP_MASTERDIR" ]; then - ARGS="-O" -fi readonly MASTERDIR="$1" readonly DISTDIR="$2" readonly HOSTDIR="$3" -readonly EXTRA_ARGS="$ARGS $4" +readonly EXTRA_ARGS="$4" readonly CMD="$5" shift 5 diff --git a/xbps-src b/xbps-src index 246938dbde7..c273448a453 100755 --- a/xbps-src +++ b/xbps-src @@ -570,6 +570,15 @@ for i in REPOSITORY DESTDIR BUILDDIR SRCDISTDIR; do unset val done +# A temporary masterdir requires xbps-uchroot(8) and -O to use overlayfs +# on tmpfs (available with xbps-0.45). +if [ -z "$IN_CHROOT" -a -n "$XBPS_TEMP_MASTERDIR" ]; then + if [ "$XBPS_CHROOT_CMD" != "uchroot" ]; then + echo "ERROR: -t requires XBPS_CHROOT_CMD=uchroot, exiting..." + exit 1 + fi + export XBPS_CHROOT_CMD_ARGS="-O" +fi # # Sanitize PATH. #