[PATCH 01/15] If directories are in $KEEPFILES, copy them to the second stage as well.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is occasionally needed for things such as directories in /etc or
/var.
---
 scripts/upd-instroot |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/scripts/upd-instroot b/scripts/upd-instroot
index f67c09e..cfb13c3 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
@@ -182,6 +193,7 @@ expandPackageSet() {
 	    instFile $filespec $PKGDEST
 	else
 	    for i in `find $filespec -type f` ; do instFile $i $PKGDEST ; done
+	    for d in `find $filespec -type d` ; do instDir $d $PKGDEST ; done
 	fi
       done
     done
-- 
1.5.3.4

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux