[arch-projects] [devtools] [PATCH] makechrootpkg: support absolute paths for chroot copy
Florian Pritz
bluewind at xinu.at
Mon Jul 25 14:28:31 EDT 2011
Signed-off-by: Florian Pritz <bluewind at xinu.at>
---
makechrootpkg | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/makechrootpkg b/makechrootpkg
index 90c60c5..52071c2 100755
--- a/makechrootpkg
+++ b/makechrootpkg
@@ -74,8 +74,12 @@ done
# Canonicalize chrootdir, getting rid of trailing /
chrootdir=$(readlink -e "$chrootdir")
-[[ -z $copy ]] && copy=$default_copy
-copydir="$chrootdir/$copy"
+if [[ ${copy:0:1} = "/" ]]; then
+ copydir=$copy
+else
+ [[ -z $copy ]] && copy=$default_copy
+ copydir="$chrootdir/$copy"
+fi
# Pass all arguments after -- right to makepkg
MAKEPKG_ARGS="$MAKEPKG_ARGS ${*:$OPTIND}"
--
1.7.6
More information about the arch-projects
mailing list