summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2008-02-27 23:04:46 -0500
committerJeremy Katz <katzj@redhat.com>2008-02-28 14:55:07 -0500
commit0b780f7a2b12eb67207213ec4ff3bf9814eb06ec (patch)
treeaec5e195b6060fe796839c2ecd424f0c472ced77 /scripts
parent6e48880d0b0aa76f139fdca081c5ca48c146ee82 (diff)
Take --updates with location of additional updates beyond the package set used
For testing purposes, add the ability to use a --updates to buildinstall for getting additional updates for testing.
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/buildinstall12
-rwxr-xr-xscripts/upd-instroot11
2 files changed, 21 insertions, 2 deletions
diff --git a/scripts/buildinstall b/scripts/buildinstall
index abcb066d5..624d18a5a 100755
--- a/scripts/buildinstall
+++ b/scripts/buildinstall
@@ -63,6 +63,10 @@ while [ $# -gt 0 ]; do
OUTPUT=$2
shift; shift
;;
+ --updates)
+ UPDATES=$2
+ shift; shift
+ ;;
*)
REPO=$1
@@ -138,7 +142,9 @@ MK_STAMP=./makestamp.py
BUILDINSTALL=./buildinstall
for f in $UPD_INSTROOT $MK_IMAGES $MK_STAMP $MK_TREEINFO $BUILDINSTALL; do
- if [ ! -f $f ]; then
+ if [ -f $UPDATES/usr/lib/anaconda-runtime/$f ]; then
+ cp -a $UPDATES/usr/lib/anaconda-runtime/$f* $BUILDINSTDIR/
+ elif [ ! -f $f ]; then
cp -a $BUILDINSTDIR/usr/lib/anaconda-runtime/$f* $BUILDINSTDIR/
else
cp -a $f* $BUILDINSTDIR/
@@ -151,8 +157,10 @@ MK_TREEINFO=$BUILDINSTDIR/maketreeinfo.py
MK_STAMP=$BUILDINSTDIR/makestamp.py
BUILDINSTALL=$BUILDINSTDIR/buildinstall
+if [ -n "$UPDATES" ]; then UPDATES="--updates $UPDATES"; fi
+
echo "Building images..."
-$UPD_INSTROOT $DEBUGSTR $NOGRSTR --arch $BUILDARCH --mindir $TREEDIR/minstg2 --stg2dir $TREEDIR/stage2 $yumconf
+$UPD_INSTROOT $DEBUGSTR $NOGRSTR --arch $BUILDARCH $UPDATES --mindir $TREEDIR/minstg2 --stg2dir $TREEDIR/stage2 $yumconf
echo "Writing .treeinfo file..."
$MK_TREEINFO --family="$PRODUCTSTR" ${VARIANT:+--variant="$VARIANT"} --version=$VERSION --arch=$BUILDARCH --outfile=$OUTPUT/.treeinfo
diff --git a/scripts/upd-instroot b/scripts/upd-instroot
index 045eeb2e6..c2f208479 100755
--- a/scripts/upd-instroot
+++ b/scripts/upd-instroot
@@ -49,6 +49,13 @@ while [ $# -gt 0 ]; do
shift; shift
;;
+ # a filesystem tree to use as updates. could be the output
+ # of 'make install' from anaconda...
+ --updates)
+ UPDATES=$2
+ shift; shift
+ ;;
+
*)
yumconf=$1
shift
@@ -94,6 +101,10 @@ expandPackageSet() {
if [ -z "$DEBUG" ]; then outlvl="--quiet" ; else outlvl="--verbose"; fi
yum $outlvl -c $YUMCONF -y --installroot=$YUMDIR install $RPMS 2>&1 || die "ERROR: could not install packages"
+ if [ -n "$UPDATES" ]; then
+ (cd $UPDATES; find) | (cd $UPDATES ; /bin/cpio --quiet -pmdu $YUMDIR)
+ fi
+
# figure out the theme to keep
if [ -f $YUMDIR/etc/gtk-2.0/gtkrc ]; then
gtktheme=$(grep "gtk-theme-name" $YUMDIR/etc/gtk-2.0/gtkrc | awk {'print $3;'} | sed -e 's/"//g')