summaryrefslogtreecommitdiffstats
path: root/scripts/buildinstall
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2006-06-30 18:47:10 +0000
committerJeremy Katz <katzj@redhat.com>2006-06-30 18:47:10 +0000
commita5b3731939bdd3e27d2a4c4d04eadf0b72b77e96 (patch)
tree82b1d2910b7f68a8d527280ca42513e4a28264ff /scripts/buildinstall
parentf945047d9ebd0344eea76e94cb9bba81a0cec0f1 (diff)
downloadanaconda-a5b3731939bdd3e27d2a4c4d04eadf0b72b77e96.tar.gz
anaconda-a5b3731939bdd3e27d2a4c4d04eadf0b72b77e96.tar.xz
anaconda-a5b3731939bdd3e27d2a4c4d04eadf0b72b77e96.zip
2006-06-30 Jeremy Katz <katzj@redhat.com>
* scripts/buildinstall: Nuke runroot stuff since everything is runroot'd now. Get rid of first/second run of buildinstall, --comp is now a no-op * scripts/upd-instroot: --comp argument no longer makes sense to take
Diffstat (limited to 'scripts/buildinstall')
-rwxr-xr-xscripts/buildinstall62
1 files changed, 7 insertions, 55 deletions
diff --git a/scripts/buildinstall b/scripts/buildinstall
index 8fd2c2c31..5f9425286 100755
--- a/scripts/buildinstall
+++ b/scripts/buildinstall
@@ -1,11 +1,10 @@
#!/bin/bash
usage() {
- echo "Usage: buildinstall [--comp <component>] [--pkgorder <file>] [--version <version>] [--product <product>] [--release <comment>] [--prodpath <path>] [--discs <discstring>] <root>" >&2
+ echo "Usage: buildinstall [--pkgorder <file>] [--version <version>] [--product <product>] [--release <comment>] [--prodpath <path>] [--discs <discstring>] <root>" >&2
exit 1
}
-RUN=1
PRODUCTPATH="anaconda"
while [ $# -gt 0 ]; do
@@ -39,10 +38,6 @@ while [ $# -gt 0 ]; do
DEBUGSTR="--debug"
shift
;;
- --second)
- RUN=2
- shift
- ;;
--buildinstdir)
BUILDINSTDIR=$2
shift; shift
@@ -82,7 +77,7 @@ if [ -z "$RELEASESTR" ]; then
fi
if [ -z "$DISCSTR" ]; then
- DISCSTR="1,2,3"
+ DISCSTR="ALL"
fi
if [ -z "$BUGURL" ]; then
@@ -105,7 +100,6 @@ BUILDINSTALL=$BUILDINSTDIR/buildinstall
BUILDARCH=`rpm -qp --qf "%{ARCH}" $p/$PRODUCTPATH/RPMS/anaconda-runtime-[0-9]*`
-firstRun() {
echo "Running buildinstall..."
pushd $BUILDINSTDIR
@@ -130,64 +124,22 @@ MK_IMAGES=$BUILDINSTDIR/mk-images
MK_STAMP=$BUILDINSTDIR/makestamp.py
BUILDINSTALL=$BUILDINSTDIR/buildinstall
-rm -rf $BUILDINSTDIR/usr
-
-echo "Going to run buildinstall again"
-# run it again for the second half
-if [ -x /usr/bin/runroot ]; then
- runroot $COMPNAME --onlyone --arch $BUILDARCH "$BUILDINSTALL $DEBUGSTR --buildinstdir $BUILDINSTDIR --second $PKGORDERSTR --comp $COMPNAME --version $VERSION --release '\"$RELEASESTR\"' --product '\"$PRODUCTSTR\"' --prodpath $PRODUCTPATH --discs '\"$DISCSTR\"' --bugurl '\"$BUGURL\"' $DIR"
-else
- $BUILDINSTALL $DEBUGSTR --buildinstdir $BUILDINSTDIR --second $PKGORDERSTR --comp $COMPNAME --version $VERSION --release "$RELEASESTR" --product "$PRODUCTSTR" --prodpath $PRODUCTPATH --discs "$DISCSTR" --bugurl "$BUGURL" $DIR
-fi
-
-rm -rf $BUILDINSTDIR
-}
-
-secondRun() {
echo "Building images..."
-if [ -x /usr/bin/runroot ]; then
- runroot $COMPNAME --onlyone --arch $BUILDARCH "$UPD_INSTROOT $DEBUGSTR --comp $COMPNAME $p/$PRODUCTPATH/RPMS $TREEDIR/image-template $TREEDIR/instimage"
-else
- $UPD_INSTROOT $DEBUGSTR --comp $COMPNAME $p/$PRODUCTPATH/RPMS $TREEDIR/image-template $TREEDIR/instimage
-fi
+$UPD_INSTROOT $DEBUGSTR $p/$PRODUCTPATH/RPMS $TREEDIR/image-template $TREEDIR/instimage
echo "Creating repository metadata..."
-if [ -x /usr/bin/runroot ]; then
- runroot $COMPNAME --onlyone --arch $BUILDARCH "createrepo -g $PRODUCTPATH/base/comps.xml -q $p"
-else
- createrepo -g $PRODUCTPATH/base/comps.xml -q $p
-fi
+createrepo -g $PRODUCTPATH/base/comps.xml -q $p
if [ -n "$PKGORDER" ]; then
echo "Getting package order..."
echo "PYTHONPATH=$TREEDIR/instimage/usr/lib/anaconda $TREEDIR/instimage/usr/lib/anaconda-runtime/pkgorder $p $BUILDARCH $PRODUCTPATH"
- if [ -x /usr/bin/runroot ]; then
- runroot --quiet $COMPNAME --onlyone --arch $BUILDARCH \
- "PYTHONPATH=$TREEDIR/instimage/usr/lib/anaconda $TREEDIR/instimage/usr/lib/anaconda-runtime/pkgorder $p $BUILDARCH $PRODUCTPATH" > $PKGORDER
- else
- PYTHONPATH=$TREEDIR/instimage/usr/lib/anaconda $TREEDIR/instimage/usr/lib/anaconda-runtime/pkgorder $p $BUILDARCH $PRODUCTPATH > $PKGORDER
- fi
+ PYTHONPATH=$TREEDIR/instimage/usr/lib/anaconda $TREEDIR/instimage/usr/lib/anaconda-runtime/pkgorder $p $BUILDARCH $PRODUCTPATH > $PKGORDER
fi
echo "Making images..."
-if [ -x /usr/bin/runroot ]; then
- runroot $COMPNAME --onlyone --arch $BUILDARCH "cd $BUILDINSTDIR\; ./mk-images $DEBUGSTR $p/$PRODUCTPATH/RPMS $p $TREEDIR/image-template $TREEDIR/instimage $BUILDARCH '\"$PRODUCTSTR\"' $VERSION $PRODUCTPATH '\"$BUGURL\"'"
-else
- $MK_IMAGES $DEBUGSTR $p/$PRODUCTPATH/RPMS $p $TREEDIR/image-template $TREEDIR/instimage $BUILDARCH "$PRODUCTSTR" $VERSION $PRODUCTPATH "$BUGURL"
-fi
+$MK_IMAGES $DEBUGSTR $p/$PRODUCTPATH/RPMS $p $TREEDIR/image-template $TREEDIR/instimage $BUILDARCH "$PRODUCTSTR" $VERSION $PRODUCTPATH "$BUGURL"
echo "Writing .discinfo file"
$MK_STAMP --releasestr="$RELEASESTR" --arch=$BUILDARCH --discNum="$DISCSTR" --baseDir=$PRODUCTPATH/base --packagesDir=$PRODUCTPATH/RPMS --pixmapsDir=$PRODUCTPATH/pixmaps --outfile=$p/.discinfo
-if [ -x /usr/bin/runroot ]; then
- runroot $COMPNAME --onlyone --arch $BUILDARCH "rm -rf $TREEDIR/image-template $TREEDIR/instimage"
-else
- rm -rf $TREEDIR/image-template $TREEDIR/instimage
-fi
-}
-
-if [ $RUN == 1 ]; then
- firstRun
-else
- secondRun
-fi
+rm -rf $TREEDIR/image-template $TREEDIR/instimage $BUILDINSTDIR