Okay.. Updated CVS patch is attached... I didn't get a chance to
give it a test run, but it should work just fine.. Cheers...Paul... Jeremy Katz wrote: On Fri, 2006-07-28 at 16:15 -0500, Paul B Schroeder wrote:This adds a --nogr flag to buildinstall so that you don't need to modify anaconda and update NEEDGR in upd-instroot.. Also moves some of graphics related echos inside the ifs for NEEDGR.. No sense in saying you're doing something you're not.. ;) Also fixes annoying -maxdepth flag warning I was seeing with find in the mk-images.* sources..All sounds and looks goodTested and seems to work fine for x86.. Applies cleanly against 11.0.5.. I can update it to apply cleanly to the current CVS tree if desired..This would be a big help -- things are actually quite a bit cleaner now, so it should even make things a little easier :-) Jeremy -- --- Paul B Schroeder <pschroeder "at" uplogix "dot" com> Senior Software Engineer Uplogix, Inc. (http://www.uplogix.com/) |
diff -ur anaconda.orig/scripts/buildinstall anaconda/scripts/buildinstall --- anaconda.orig/scripts/buildinstall 2006-07-21 13:59:07.000000000 -0500 +++ anaconda/scripts/buildinstall 2006-07-31 17:18:18.000000000 -0500 @@ -34,6 +34,10 @@ PRODUCTPATH=$2 shift; shift ;; + --nogr) + NOGRSTR="--nogr" + shift + ;; --debug) DEBUGSTR="--debug" shift @@ -127,7 +131,7 @@ BUILDINSTALL=$BUILDINSTDIR/buildinstall echo "Building images..." -$UPD_INSTROOT $DEBUGSTR $PKGDIR $TREEDIR/image-template $TREEDIR/instimage +$UPD_INSTROOT $DEBUGSTR $NOGRSTR $PKGDIR $TREEDIR/image-template $TREEDIR/instimage echo "Creating repository metadata..." createrepo -g $PRODUCTPATH/base/comps.xml -q $p @@ -139,7 +143,7 @@ fi echo "Making images..." -$MK_IMAGES $DEBUGSTR $PKGDIR $p $TREEDIR/image-template $TREEDIR/instimage $BUILDARCH "$PRODUCTSTR" $VERSION $PRODUCTPATH "$BUGURL" +$MK_IMAGES $DEBUGSTR $NOGRSTR $PKGDIR $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=$PKGDIR --pixmapsDir=$PRODUCTPATH/pixmaps --outfile=$p/.discinfo Only in anaconda/scripts: buildinstall.orig Only in anaconda/scripts: buildinstall.rej diff -ur anaconda.orig/scripts/mk-images anaconda/scripts/mk-images --- anaconda.orig/scripts/mk-images 2006-07-28 15:51:46.000000000 -0500 +++ anaconda/scripts/mk-images 2006-07-31 17:06:37.000000000 -0500 @@ -15,6 +15,12 @@ shift fi +NEEDGR=yes +if [ "$1" == "--nogr" ]; then + NEEDGR="" + shift +fi + if [ -z "$1" -o -z "$2" -o -z "$3" -o -z "$4" -o -z "$5" -o -z "$6" -o -z "$7" -o -z "$8" ]; then usage; fi PRODUCT=$6 Only in anaconda/scripts: mk-images.s390.orig Only in anaconda/scripts: mk-images.s390.rej diff -ur anaconda.orig/scripts/mk-images.x86 anaconda/scripts/mk-images.x86 --- anaconda.orig/scripts/mk-images.x86 2006-06-13 23:02:19.000000000 -0500 +++ anaconda/scripts/mk-images.x86 2006-07-31 17:27:52.000000000 -0500 @@ -12,17 +12,21 @@ # prepare a directory with the kernel, initrd, and various message files # used to populate a boot image prepareBootTree() { - (cd $BOOTDISKDIR; find . ! -name "*.msg" -maxdepth 1 ! -type d | cpio --quiet -p $MBD_BOOTTREE) + (cd $BOOTDISKDIR; find . -maxdepth 1 ! -name "*.msg" ! -type d | cpio --quiet -p $MBD_BOOTTREE) cp $MBD_FSIMAGE $MBD_BOOTTREE/initrd.img cp $KERNELROOT/boot/vmlinuz-* $MBD_BOOTTREE/vmlinuz - $IMGPATH/usr/lib/anaconda-runtime/splashtolss.sh $BOOTDISKDIR/syslinux-splash.png $BOOTDISKDIR/splash.lss - if [ $? != 0 ]; then - echo $0: Failed to create splash.lss - exit 1 - fi - cp $BOOTDISKDIR/splash.lss $MBD_BOOTTREE/splash.lss - rm -f $MBD_BOOTTREE/syslinux-splash.png + + if [ -n "$NEEDGR" ]; then + $IMGPATH/usr/lib/anaconda-runtime/splashtolss.sh $BOOTDISKDIR/syslinux-splash.png $BOOTDISKDIR/splash.lss + if [ $? != 0 ]; then + echo $0: Failed to create splash.lss + exit 1 + fi + cp $BOOTDISKDIR/splash.lss $MBD_BOOTTREE/splash.lss + rm -f $MBD_BOOTTREE/syslinux-splash.png + fi + rm -f $MBD_BOOTTREE/memtest* for file in $BOOTDISKDIR/*.msg; do filename=`basename $file` diff -ur anaconda.orig/scripts/upd-instroot anaconda/scripts/upd-instroot --- anaconda.orig/scripts/upd-instroot 2006-07-28 15:32:30.000000000 -0500 +++ anaconda/scripts/upd-instroot 2006-07-31 17:10:30.000000000 -0500 @@ -2,12 +2,18 @@ ORIGDIR=`pwd` DEBUG="" +NEEDGR=yes if [ "$1" == "--debug" ]; then DEBUG="--debug" shift fi +if [ "$1" == "--nogr" ]; then + NEEDGR="" + shift +fi + if [ -z "$1" ]; then echo "upd-instroot: updates instimage from a Red Hat RPMS directory" echo "usage: $0 <packagedir> [templatedir] [instroot]" @@ -33,7 +39,6 @@ LIBDIR=lib fi -NEEDGR=yes prunePackageList() { PACKAGEPATH=$1 @@ -62,12 +67,12 @@ [ -d $PKGDEST ] || die "ERROR: directory missing: $PKGDEST" for n in $RPMS; do - [ -n "$DEBUG" ] && echo -ne "\rExpanding packages..." $(basename $n) + [ -n "$DEBUG" ] && echo -e "\rExpanding packages..." $(basename $n) if [ "$(rpm --nosignature --nodigest -qp --qf '%{NAME}' $n)" = "tzdata" ] ; then TZDATA=$n fi rpm2cpio $n | (cd $PKGDEST; cpio -E $KEEPFILES --quiet -iumd) - [ -n "$DEBUG" ] && echo -ne "\rExpanding packages..." "$(basename $n | sed 's/./ /g')" + [ -n "$DEBUG" ] && echo -e "\rExpanding packages..." "$(basename $n | sed 's/./ /g')" done pushd $PKGDEST/$LIBDIR >/dev/null 2>&1 if [ -d obsolete/linuxthreads/ ]; then @@ -1019,13 +1024,15 @@ done # fixup joe links -ln -fs jpicorc $DESTGR/etc/joe/picorc -ln -fs jpicorc $DESTGR/etc/joe/jnanorc -ln -fs jpicorc $DESTGR/etc/joe/nanorc -ln -fs jmacsrc $DESTGR/etc/joe/emacsrc -ln -fs jmacs $DESTGR/usr/bin/emacs -ln -fs jpico $DESTGR/usr/bin/pico -ln -fs jpico $DESTGR/usr/bin/nano +if [ -n "$NEEDGR" ]; then + ln -fs jpicorc $DESTGR/etc/joe/picorc + ln -fs jpicorc $DESTGR/etc/joe/jnanorc + ln -fs jpicorc $DESTGR/etc/joe/nanorc + ln -fs jmacsrc $DESTGR/etc/joe/emacsrc + ln -fs jmacs $DESTGR/usr/bin/emacs + ln -fs jpico $DESTGR/usr/bin/pico + ln -fs jpico $DESTGR/usr/bin/nano +fi # create selinux config if [ -e $DEST/etc/selinux/targeted ]; then @@ -1079,15 +1086,15 @@ cp $DEST/etc/libuser.conf $DESTGR/etc/libuser.conf # fixup man.config to point into /mnt/sysimage for rescue -echo "Fixing up /etc/man.config to point into /mnt/sysimage" if [ -n "$NEEDGR" ]; then + echo "Fixing up /etc/man.config to point into /mnt/sysimage" mv $DESTGR/etc/man.config $DESTGR/etc/man.config-old cat $DESTGR/etc/man.config-old | sed 's^/usr/bin^/mnt/sysimage/usr/bin^' | sed 's^/bin/cat^/mnt/sysimage/usr/bin/cat^' > $DESTGR/etc/man.config rm -f $DESTGR/etc/man.config-old fi -echo "Running mkfontdir..." if [ -n "$NEEDGR" ]; then + echo "Running mkfontdir..." mkfontdir $DESTGR/usr/share/X11/fonts/* fi @@ -1099,8 +1106,8 @@ mkdir $DEST/etc/selinux cp -r $DESTGR/etc/selinux/* $DEST/etc/selinux/ -echo "Getting pango modules" if [ -n "$NEEDGR" ]; then + echo "Getting pango modules" # sick sick sick hack for pango-querymodules being -32 or -64 mv $DESTGR/usr/bin/pango-querymodules* $DESTGR/usr/bin/pango-querymodules /usr/sbin/chroot $DESTGR /usr/bin/pango-querymodules > $DESTGR/etc/pango/pango.modules @@ -1127,15 +1134,15 @@ mkdir -p $DESTGR/etc/gtk-2.0/$HOSTTRIPLET -echo "Getting gtk2 input method modules" if [ -n "$NEEDGR" ]; then + echo "Getting gtk2 input method modules" mv $DESTGR/usr/bin/gtk-query-immodules-2.0* $DESTGR/usr/bin/gtk-query-immodules-2.0 /usr/sbin/chroot $DESTGR /usr/bin/gtk-query-immodules-2.0 > $DESTGR/etc/gtk-2.0/$HOSTTRIPLET/gtk.immodules rm -f $DESTGR/usr/bin/gtk-query-immodules-2.0 fi -echo "Getting gtk2 gdk-pixbuf loaders" if [ -n "$NEEDGR" ]; then + echo "Getting gtk2 gdk-pixbuf loaders" mv $DESTGR/usr/bin/gdk-pixbuf-query-loaders* $DESTGR/usr/bin/gdk-pixbuf-query-loaders /usr/sbin/chroot $DESTGR /usr/bin/gdk-pixbuf-query-loaders > $DESTGR/etc/gtk-2.0/$HOSTTRIPLET/gdk-pixbuf.loaders rm -f $DESTGR/usr/bin/gdk-pixbuf-query-loaders @@ -1241,8 +1248,8 @@ done fi -echo "Creating fontconfig cache" if [ -n "$NEEDGR" ]; then + echo "Creating fontconfig cache" /usr/sbin/chroot $DESTGR /usr/bin/fc-cache rm -f $DESTGR/usr/bin/fc-cache fi Only in anaconda/scripts: upd-instroot.orig Only in anaconda/scripts: upd-instroot.rej