summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2007-12-06 15:51:24 -0500
committerBill Nottingham <notting@redhat.com>2007-12-07 13:17:45 -0500
commitaae18212546be9998cfc089d9318fa6814273c73 (patch)
treefa366f20d15db8a1b4897e31fe22e155b27f0f9d /scripts
parent7b48feb4df28c9eeeedf23018690c8d01598c795 (diff)
downloadanaconda-aae18212546be9998cfc089d9318fa6814273c73.tar.gz
anaconda-aae18212546be9998cfc089d9318fa6814273c73.tar.xz
anaconda-aae18212546be9998cfc089d9318fa6814273c73.zip
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.
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/upd-instroot12
1 files changed, 12 insertions, 0 deletions
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