aboutsummaryrefslogtreecommitdiff
path: root/bootstrap
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2005-05-19 15:25:55 +0000
committerSergey Poznyakoff <gray@gnu.org.ua>2005-05-19 15:25:55 +0000
commitfaaeab2ffaf01665f3925001a15876ff6462087a (patch)
treecad612e8d1b20f3360e592f9667eee4c671e42c3 /bootstrap
parent531dad5f50ede598dccfe7e3d65e4c55592c61c1 (diff)
downloadcpio-faaeab2ffaf01665f3925001a15876ff6462087a.tar.gz
cpio-faaeab2ffaf01665f3925001a15876ff6462087a.tar.bz2
(copy_files): Accept optional third argument: a prefix
to be appended to destination file names. Import paxutils/paxlib files.
Diffstat (limited to 'bootstrap')
-rwxr-xr-xbootstrap13
1 files changed, 11 insertions, 2 deletions
diff --git a/bootstrap b/bootstrap
index 6e84bd6..1ec19ff 100755
--- a/bootstrap
+++ b/bootstrap
@@ -185,14 +185,22 @@ if [ -r $PAXUTILS_SRCDIR/gnulib.modules ]; then
fi
# copy_files srcdir dstdir
+# copy_files srcdir dstdir
copy_files() {
for file in `cat $1/DISTFILES`
do
case $file in
"#*") continue;;
esac
- echo "$0: Copying file $1/$file"
- cp -p $1/$file $2/`expr $file : '.*/\(.*\)'`
+ dst=`echo $file | sed 's^.*/^^'`
+ if [ $# -eq 3 ]; then
+ case $dst in
+ ${3}*) ;;
+ *) dst=${3}$dst;;
+ esac
+ fi
+ echo "$0: Copying file $1/$file to $2/$dst"
+ cp -p $1/$file $2/$dst
done
}
@@ -217,6 +225,7 @@ do
copy_files ${PAXUTILS_SRCDIR}/$dir $dir
done
+copy_files ${PAXUTILS_SRCDIR}/paxlib lib pax
# Get gnulib files.

Return to:

Send suggestions and report system problems to the System administrator.