From 4abfdaa8c9fa4646f3ba7e9c1bb1f3eb47061f9d Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Sun, 29 Jan 2017 23:46:38 -0500 Subject: makechrootpkg.sh.patch: Update to latest devtools-par master. --- src/chroot-tools/makechrootpkg.sh.patch | 36 +++++++++++++++++---------------- 1 file changed, 19 insertions(+), 17 deletions(-) (limited to 'src/chroot-tools/makechrootpkg.sh.patch') diff --git a/src/chroot-tools/makechrootpkg.sh.patch b/src/chroot-tools/makechrootpkg.sh.patch index 6e5e45a..648f574 100644 --- a/src/chroot-tools/makechrootpkg.sh.patch +++ b/src/chroot-tools/makechrootpkg.sh.patch @@ -1,5 +1,5 @@ ---- makechrootpkg.sh.in 2016-06-09 16:36:04.300623877 -0400 -+++ makechrootpkg.sh.ugly 2016-06-09 16:36:26.496802844 -0400 +--- makechrootpkg.sh.in 2017-01-29 23:29:48.520332237 -0500 ++++ makechrootpkg.sh.ugly 2017-01-29 23:31:17.341897626 -0500 @@ -1,4 +1,6 @@ #!/bin/bash +# License: GNU GPLv2 @@ -27,7 +27,7 @@ usage() { echo "Usage: ${0##*/} [options] -r [--] [makepkg args]" -@@ -68,28 +72,51 @@ +@@ -68,13 +72,21 @@ } # {{{ functions @@ -50,6 +50,8 @@ done return 0 +@@ -135,16 +147,31 @@ + btrfs subvolume delete "$dir" } -create_chroot() { @@ -85,8 +87,8 @@ + stat_busy "Synchronizing chroot copy [%s] -> [%s]" "$chrootdir/root" "$copydir" if [[ "$chroottype" == btrfs ]] && ! mountpoint -q "$copydir"; then if [[ -d $copydir ]]; then - btrfs subvolume delete "$copydir" >/dev/null || -@@ -105,14 +132,18 @@ + btrfs_subvolume_delete "$copydir" >/dev/null || +@@ -160,14 +187,18 @@ # Drop the read lock again lock_close 8 @@ -106,9 +108,9 @@ + + stat_busy "Removing chroot copy [%s]" "$copydir" if [[ "$chroottype" == btrfs ]] && ! mountpoint -q "$copydir"; then - btrfs subvolume delete "$copydir" >/dev/null || + btrfs_subvolume_delete "$copydir" >/dev/null || die "Unable to delete subvolume %s" "$copydir" -@@ -127,9 +158,14 @@ +@@ -182,9 +213,14 @@ stat_done } @@ -123,7 +125,7 @@ for install_pkg in "${install_pkgs[@]}"; do pkgname="${install_pkg##*/}" cp "$install_pkg" "$copydir/$pkgname" -@@ -142,11 +178,19 @@ +@@ -197,11 +233,19 @@ rm "$copydir/$pkgname" done @@ -145,7 +147,7 @@ $repack || rm -rf "$copydir/build" mkdir -p "$copydir/build" -@@ -193,12 +237,12 @@ +@@ -248,12 +292,12 @@ printf 'builduser:x:%d:100:builduser:/build:/bin/bash\n' "$builduser_uid" >>"$copydir/etc/passwd" chown -R "$builduser_uid" "$copydir"/{build,pkgdest,srcpkgdest,logdest,srcdest,startdir} @@ -160,7 +162,7 @@ sed -i '/^PACKAGER=/d' "$copydir/etc/makepkg.conf" echo "PACKAGER='${PACKAGER}'" >> "$copydir/etc/makepkg.conf" fi -@@ -211,10 +255,25 @@ +@@ -266,10 +310,25 @@ chmod 440 "$copydir/etc/sudoers.d/builduser-pacman" fi @@ -186,7 +188,7 @@ declare -f _chrootbuild printf '_chrootbuild "$@" || exit\n' -@@ -231,13 +290,19 @@ +@@ -286,13 +345,19 @@ chmod +x "$copydir/chrootbuild" } @@ -208,7 +210,7 @@ makepkg --config="$copydir/etc/makepkg.conf" --verifysource -o else ( export SRCDEST BUILDDIR="$builddir" -@@ -247,10 +312,10 @@ +@@ -302,10 +367,10 @@ (( $? != 0 )) && die "Could not download sources." # Clean up garbage from verifysource @@ -221,7 +223,7 @@ # This function isn't run in makechrootpkg, # so no global variables -@@ -259,6 +324,7 @@ +@@ -314,6 +379,7 @@ shopt -s nullglob # XXX: Workaround makepkg disliking read-only dirs @@ -229,7 +231,7 @@ ln -sft /srcdest /srcdest_host/* ln -sft /startdir /startdir_host/* -@@ -288,15 +354,42 @@ +@@ -343,15 +409,42 @@ exit 1 fi @@ -273,7 +275,7 @@ for l in "$copydir"/logdest/*; do [[ $l == */logpipe.* ]] && continue chown "$src_owner" "$l" -@@ -310,6 +403,9 @@ +@@ -365,6 +458,9 @@ } # }}} @@ -283,7 +285,7 @@ orig_argv=("$@") while getopts 'hcur:I:l:nTD:d:' arg; do -@@ -375,30 +471,45 @@ +@@ -430,30 +526,45 @@ [[ -d $SRCPKGDEST ]] || SRCPKGDEST=$PWD [[ -d $LOGDEST ]] || LOGDEST=$PWD @@ -335,7 +337,7 @@ if (( ret != 0 )); then if $temp_chroot; then -@@ -409,3 +520,4 @@ +@@ -464,3 +575,4 @@ else true fi -- cgit v1.2.2