From aae18212546be9998cfc089d9318fa6814273c73 Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Thu, 6 Dec 2007 15:51:24 -0500 Subject: If directories are in $KEEPFILES, copy them to the second stage as well. This is occasionally needed for things such as directories in /etc or /var. --- scripts/upd-instroot | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'scripts') diff --git a/scripts/upd-instroot b/scripts/upd-instroot index 597b4d7f8..d44830b11 100755 --- a/scripts/upd-instroot +++ b/scripts/upd-instroot @@ -144,6 +144,17 @@ instFile() { done } +instDir() { + DIR=$1 + DESTROOT=$2 + + echo "Installing $DIR" + if [ -d $DESTROOT/$DIR -o -h $DESTROOT/$DIR ]; then + return + fi + cp -a --parents $DIR $DESTROOT/ +} + expandPackageSet() { YUMCONF=$1 YUMDIR=$2 @@ -183,6 +194,7 @@ expandPackageSet() { else for i in `find $filespec -type f` ; do instFile $i $PKGDEST ; done for i in `find $filespec -type l` ; do instFile $i $PKGDEST ; done + for d in `find $filespec -type d` ; do instDir $d $PKGDEST ; done fi done done -- cgit