Hi there,
here's a couple of patches that fix tab usage vs. the use of spaces in
some of the scripts that I needed to edit for the next patch.
58114b660e443a656bb37ea2265bdb98c7061e33
88d0046fd3a4889232b512cab7a2a62fbe9b523c
c97837cf01ccb9af11a80fb49ec778e907c8e3a0
fbcbc55903973a43f6ff92beb1538095c1466269
from git://git.kanarip.com/anaconda
, or, if mailman doesn't destroy the patches, the attached versions.
Kind regards,
Jeroen van Meeuwen
-kanarip
>From 58114b660e443a656bb37ea2265bdb98c7061e33 Mon Sep 17 00:00:00 2001
From: Jeroen van Meeuwen (Fedora Unity) <kanarip@xxxxxxxxxxxxxxx>
Date: Sun, 11 Jan 2009 18:12:23 -0500
Subject: [PATCH] Fix indentation in buildinstall script
---
scripts/buildinstall | 113 +++++++++++++++++++++++++-------------------------
1 files changed, 56 insertions(+), 57 deletions(-)
diff --git a/scripts/buildinstall b/scripts/buildinstall
index 8167dcc..818959d 100755
--- a/scripts/buildinstall
+++ b/scripts/buildinstall
@@ -28,67 +28,66 @@ die() {
}
usage() {
- echo "Usage: buildinstall --version <version> --product <product> --release <comment> [--output outputdir] [--discs <discstring>] <root>" >&2
- exit 1
+ echo "Usage: buildinstall --version <version> --product <product> --release <comment> [--output outputdir] [--discs <discstring>] <root>" >&2
+ exit 1
}
PRODUCTPATH="anaconda"
while [ $# -gt 0 ]; do
case $1 in
- # general options affecting how we build things
- --nogr)
- NOGRSTR="--nogr"
- shift
- ;;
- --debug)
- DEBUGSTR="--debug"
- shift
- ;;
-
- # release information
- --version)
- VERSION=$2
- shift; shift
- ;;
- --release)
- RELEASESTR=$2
- shift; shift
- ;;
+ # general options affecting how we build things
+ --nogr)
+ NOGRSTR="--nogr"
+ shift
+ ;;
+ --debug)
+ DEBUGSTR="--debug"
+ shift
+ ;;
+
+ # release information
+ --version)
+ VERSION=$2
+ shift; shift
+ ;;
+ --release)
+ RELEASESTR=$2
+ shift; shift
+ ;;
--product)
- PRODUCTSTR=$2
- shift; shift
- ;;
- --variant)
- VARIANT=$2
- shift; shift
- ;;
- --bugurl)
- BUGURL=$2
- shift; shift
- ;;
-
- --output)
- OUTPUT=$2
- shift; shift
- ;;
- --updates)
- UPDATES=$2
- shift; shift
- ;;
- --mirrorlist)
- MIRRORLIST="$MIRRORLIST $2"
- shift; shift
- ;;
-
- *)
- if [ -z "$REPO" ]; then
- REPO=$1
- else
- EXTRA_REPOS="$EXTRA_REPOS $1"
- fi
- shift
- ;;
+ PRODUCTSTR=$2
+ shift; shift
+ ;;
+ --variant)
+ VARIANT=$2
+ shift; shift
+ ;;
+ --bugurl)
+ BUGURL=$2
+ shift; shift
+ ;;
+ --output)
+ OUTPUT=$2
+ shift; shift
+ ;;
+ --updates)
+ UPDATES=$2
+ shift; shift
+ ;;
+ --mirrorlist)
+ MIRRORLIST="$MIRRORLIST $2"
+ shift; shift
+ ;;
+
+ *)
+ if [ -z "$REPO" ]; then
+ REPO=$1
+ else
+ EXTRA_REPOS="$EXTRA_REPOS $1"
+ fi
+ shift
+ ;;
esac
done
@@ -189,11 +188,11 @@ BUILDINSTALL=./buildinstall
for f in $UPD_INSTROOT $MK_IMAGES $MK_STAMP $MK_TREEINFO $BUILDINSTALL; do
if [ -n "$UPDATES" -a -f $UPDATES/usr/lib/anaconda-runtime/$f ]; then
- cp -a $UPDATES/usr/lib/anaconda-runtime/$f* $BUILDINSTDIR/
+ cp -a $UPDATES/usr/lib/anaconda-runtime/$f* $BUILDINSTDIR/
elif [ ! -f $f ]; then
- cp -a $BUILDINSTDIR/usr/lib/anaconda-runtime/$f* $BUILDINSTDIR/
+ cp -a $BUILDINSTDIR/usr/lib/anaconda-runtime/$f* $BUILDINSTDIR/
else
- cp -a $f* $BUILDINSTDIR/
+ cp -a $f* $BUILDINSTDIR/
fi
done
--
1.6.0.6
>From 88d0046fd3a4889232b512cab7a2a62fbe9b523c Mon Sep 17 00:00:00 2001
From: Jeroen van Meeuwen (Fedora Unity) <kanarip@xxxxxxxxxxxxxxx>
Date: Sun, 11 Jan 2009 18:31:59 -0500
Subject: [PATCH] Fix the indentation in mk-images
---
scripts/mk-images | 596 ++++++++++++++++++++++++++---------------------------
1 files changed, 295 insertions(+), 301 deletions(-)
diff --git a/scripts/mk-images b/scripts/mk-images
index 9e68fac..20282a4 100755
--- a/scripts/mk-images
+++ b/scripts/mk-images
@@ -25,7 +25,7 @@ IMAGEUUID=$(date +%Y%m%d%H%M).$(uname -i)
TMPDIR=${TMPDIR:-/tmp}
usage () {
- echo "usage: mk-images <pkgsrc> <toplevel> <template> <imgdir> <buildarch> <productname> <version> [<productpath>]"
+ echo "usage: mk-images <pkgsrc> <toplevel> <template> <imgdir> <buildarch> <productname> <version> [<productpath>]"
exit 0
}
@@ -35,65 +35,54 @@ BOOTISO="boot.iso"
while [ $# -gt 0 ]; do
case $1 in
- --debug)
- DEBUG="--debug"
- shift
- ;;
-
- --noiso)
- BOOTISO=""
- shift
- ;;
-
- --arch)
- BUILDARCH=$2
- shift; shift
- ;;
-
- --imgdir)
- IMGPATH=$2
- shift; shift
- ;;
-
- --product)
- PRODUCT=$2
- shift; shift
- ;;
-
- --version)
- VERSION=$2
- shift; shift
- ;;
-
- --bugurl)
- BUGURL=$2
- shift; shift
- ;;
-
- --output)
- TOPDESTPATH=$2
- shift; shift
- ;;
-
- --nogr)
- echo "*** DeprecationWarning: ignoring --nogr option." >&2
- shift
- ;;
-
- --mindir)
- echo "*** DeprecationWarning: ignoring --mindir option." >&2
- shift; shift
- ;;
-
- --stg2dir)
- echo "*** DeprecationWarning: please use --imgdir instead of --stg2dir." >&2
- shift; shift
- ;;
-
- *)
- yumconf=$1
- shift
- ;;
+ --debug)
+ DEBUG="--debug"
+ shift
+ ;;
+ --noiso)
+ BOOTISO=""
+ shift
+ ;;
+ --arch)
+ BUILDARCH=$2
+ shift; shift
+ ;;
+ --imgdir)
+ IMGPATH=$2
+ shift; shift
+ ;;
+ --product)
+ PRODUCT=$2
+ shift; shift
+ ;;
+ --version)
+ VERSION=$2
+ shift; shift
+ ;;
+ --bugurl)
+ BUGURL=$2
+ shift; shift
+ ;;
+ --output)
+ TOPDESTPATH=$2
+ shift; shift
+ ;;
+ --nogr)
+ echo "*** DeprecationWarning: ignoring --nogr option." >&2
+ shift
+ ;;
+ --mindir)
+ echo "*** DeprecationWarning: ignoring --mindir option." >&2
+ shift; shift
+ ;;
+ --stg2dir)
+ echo "*** DeprecationWarning: please use --imgdir instead of --stg2dir." >&2
+ shift; shift
+ ;;
+ *)
+ yumconf=$1
+ shift
+ ;;
esac
done
@@ -122,110 +111,110 @@ INITRDMODS="$USBMODS $FIREWIREMODS $IDEMODS $SCSIMODS $FSMODS $LVMMODS $RAIDMODS
. $(dirname $0)/buildinstall.functions
# Set, verify, and create paths
- IMAGEPATH=$TOPDESTPATH/images
- FULLMODPATH=$TMPDIR/instimagemods.$$
- FINALFULLMODPATH=$IMGPATH/modules
- INSTIMGPATH=$TOPDESTPATH/images
- KERNELBASE=$TMPDIR/updboot.kernel.$$
-
- KERNELNAME=vmlinuz
- if [ "$BUILDARCH" = "ia64" ]; then
- KERNELDIR="/boot/efi/EFI/redhat"
- else
- KERNELDIR="/boot"
- fi
-
- if [ "$BUILDARCH" = "sparc64" ]; then
- BASEARCH=sparc
- else
- BASEARCH=$BUILDARCH
- fi
+IMAGEPATH=$TOPDESTPATH/images
+FULLMODPATH=$TMPDIR/instimagemods.$$
+FINALFULLMODPATH=$IMGPATH/modules
+INSTIMGPATH=$TOPDESTPATH/images
+KERNELBASE=$TMPDIR/updboot.kernel.$$
+
+KERNELNAME=vmlinuz
+if [ "$BUILDARCH" = "ia64" ]; then
+ KERNELDIR="/boot/efi/EFI/redhat"
+else
+ KERNELDIR="/boot"
+fi
- # explicit block size setting for some arches (FIXME: we compose
- # ppc64-ish trees as ppc, so we have to set the "wrong" block size)
- if [ "$BUILDARCH" = "sparc64" ]; then
- CRAMBS="--blocksize 8192"
- elif [ "$BUILDARCH" = "sparc" ]; then
- CRAMBS="--blocksize 4096"
- else
- CRAMBS=""
- fi
+if [ "$BUILDARCH" = "sparc64" ]; then
+ BASEARCH=sparc
+else
+ BASEARCH=$BUILDARCH
+fi
- if [ $BUILDARCH = x86_64 -o $BUILDARCH = s390x ]; then
- LIBDIR=lib64
- else
- LIBDIR=lib
- fi
+# explicit block size setting for some arches (FIXME: we compose
+# ppc64-ish trees as ppc, so we have to set the "wrong" block size)
+if [ "$BUILDARCH" = "sparc64" ]; then
+ CRAMBS="--blocksize 8192"
+elif [ "$BUILDARCH" = "sparc" ]; then
+ CRAMBS="--blocksize 4096"
+else
+ CRAMBS=""
+fi
- rm -rf $IMAGEPATH
- rm -rf $FULLMODPATH
- rm -rf $FINALFULLMODPATH
- rm -rf $KERNELBASE
- mkdir -p $IMAGEPATH
- mkdir -p $FULLMODPATH
- mkdir -p $FINALFULLMODPATH
- mkdir -p $KERNELBASE
- mkdir -p $INSTIMGPATH
+if [ $BUILDARCH = x86_64 -o $BUILDARCH = s390x ]; then
+ LIBDIR=lib64
+else
+ LIBDIR=lib
+fi
+
+rm -rf $IMAGEPATH
+rm -rf $FULLMODPATH
+rm -rf $FINALFULLMODPATH
+rm -rf $KERNELBASE
+mkdir -p $IMAGEPATH
+mkdir -p $FULLMODPATH
+mkdir -p $FINALFULLMODPATH
+mkdir -p $KERNELBASE
+mkdir -p $INSTIMGPATH
# Stuff that we need
- TRIMPCIIDS=$IMGPATH/usr/lib/anaconda-runtime/trimpciids
- GETKEYMAPS=$IMGPATH/usr/lib/anaconda-runtime/getkeymaps
- GENINITRDSZ=$IMGPATH/usr/lib/anaconda-runtime/geninitrdsz
- MKS390CDBOOT=$IMGPATH/usr/lib/anaconda-runtime/mk-s390-cdboot
- GENMODINFO=$IMGPATH/usr/lib/anaconda-runtime/genmodinfo
- KEYMAPS=$TMPDIR/keymaps-$BUILDARCH.$$
- SCREENFONT=$IMGPATH/usr/lib/anaconda-runtime/screenfont-${BASEARCH}.gz
- MODLIST=$IMGPATH/usr/lib/anaconda-runtime/modlist
- MODINFO=$TMPDIR/modinfo-$BUILDARCH.$$
- LOADERBINDIR=$IMGPATH/usr/lib/anaconda-runtime/loader
- BOOTDISKDIR=$IMGPATH/usr/lib/anaconda-runtime/boot
- LANGTABLE=$IMGPATH/usr/lib/anaconda/lang-table
- PCIIDS=$IMGPATH/usr/share/hwdata/pci.ids
- XDRIVERS=$IMGPATH/usr/share/hwdata/videoaliases
- XDRIVERDESCS=$IMGPATH/usr/share/hwdata/videodrivers
-
- REQUIREMENTS="$TRIMPCIIDS $PCIIDS $XDRIVERDESCS $GENMODINFO
- $LANGTABLE $GETKEYMAPS"
-
- dieLater=
- for n in $REQUIREMENTS; do
- if [ ! -f $n ]; then
- echo "$n doesn't exist"
- dieLater=1
- fi
- done
+TRIMPCIIDS=$IMGPATH/usr/lib/anaconda-runtime/trimpciids
+GETKEYMAPS=$IMGPATH/usr/lib/anaconda-runtime/getkeymaps
+GENINITRDSZ=$IMGPATH/usr/lib/anaconda-runtime/geninitrdsz
+MKS390CDBOOT=$IMGPATH/usr/lib/anaconda-runtime/mk-s390-cdboot
+GENMODINFO=$IMGPATH/usr/lib/anaconda-runtime/genmodinfo
+KEYMAPS=$TMPDIR/keymaps-$BUILDARCH.$$
+SCREENFONT=$IMGPATH/usr/lib/anaconda-runtime/screenfont-${BASEARCH}.gz
+MODLIST=$IMGPATH/usr/lib/anaconda-runtime/modlist
+MODINFO=$TMPDIR/modinfo-$BUILDARCH.$$
+LOADERBINDIR=$IMGPATH/usr/lib/anaconda-runtime/loader
+BOOTDISKDIR=$IMGPATH/usr/lib/anaconda-runtime/boot
+LANGTABLE=$IMGPATH/usr/lib/anaconda/lang-table
+PCIIDS=$IMGPATH/usr/share/hwdata/pci.ids
+XDRIVERS=$IMGPATH/usr/share/hwdata/videoaliases
+XDRIVERDESCS=$IMGPATH/usr/share/hwdata/videodrivers
+
+REQUIREMENTS="$TRIMPCIIDS $PCIIDS $XDRIVERDESCS $GENMODINFO
+ $LANGTABLE $GETKEYMAPS"
+
+dieLater=
+for n in $REQUIREMENTS; do
+ if [ ! -f $n ]; then
+ echo "$n doesn't exist"
+ dieLater=1
+ fi
+done
- for n in $BOOTDISKDIR; do
- if [ ! -d $n ]; then
- echo "$n doesn't exist"
- dieLater=1
- fi
- done
+for n in $BOOTDISKDIR; do
+ if [ ! -d $n ]; then
+ echo "$n doesn't exist"
+ dieLater=1
+ fi
+done
- if [ -n "$dieLater" ]; then exit 1; fi
+if [ -n "$dieLater" ]; then exit 1; fi
- if [ "$BUILDARCH" != "s390" -a "$BUILDARCH" != "s390x" ]; then
- # go ahead and create the keymaps so we only have to do it once
- if [ -f $IMGPATH/usr/lib/anaconda-runtime/keymaps-override-$BUILDARCH ]; then
- echo "Found keymap override, using it"
- cp $IMGPATH/usr/lib/anaconda-runtime/keymaps-override-$BUILDARCH $KEYMAPS
- else
- echo "Running: $GETKEYMAPS $BUILDARCH $KEYMAPS $IMGPATH"
- $GETKEYMAPS $BUILDARCH $KEYMAPS $IMGPATH
- if [ $? != 0 ]; then
- echo "Unable to create keymaps and thus can't create initrd."
- exit 1
- fi
- fi
+if [ "$BUILDARCH" != "s390" -a "$BUILDARCH" != "s390x" ]; then
+ # go ahead and create the keymaps so we only have to do it once
+ if [ -f $IMGPATH/usr/lib/anaconda-runtime/keymaps-override-$BUILDARCH ]; then
+ echo "Found keymap override, using it"
+ cp $IMGPATH/usr/lib/anaconda-runtime/keymaps-override-$BUILDARCH $KEYMAPS
+ else
+ echo "Running: $GETKEYMAPS $BUILDARCH $KEYMAPS $IMGPATH"
+ $GETKEYMAPS $BUILDARCH $KEYMAPS $IMGPATH
+ if [ $? != 0 ]; then
+ echo "Unable to create keymaps and thus can't create initrd."
+ exit 1
+ fi
fi
-
+fi
+
findPackage() {
name=$1
pkg=$(repoquery --qf "%{NAME}-%{VERSION}-%{RELEASE}.%{ARCH}" -c $yumconf --archlist=$KERNELARCH $name.$KERNELARCH)
if [ -n "$pkg" ]; then
- echo $pkg
- return
+ echo $pkg
+ return
fi
echo "cannot find package $name" >&2
}
@@ -257,22 +246,22 @@ resdeps () {
expandModuleSet() {
SET=""
for name in $1; do
- char=$(echo $name | cut -c1)
+ char=$(echo $name | cut -c1)
if [ $char = '=' ]; then
- NAME=$(echo $name | cut -c2-)
- if [ "$NAME" = "ata" ]; then
- SET="$SET $(cat $MBD_DIR/lib/modules/$kernel/modules.block |egrep '(ata|ahci)' |sed -e 's/.ko//')"
- elif [ "$NAME" = "scsi" ]; then
- SET="$SET $(cat $MBD_DIR/lib/modules/$kernel/modules.block) |sed -e 's/.ko//')"
- else
+ NAME=$(echo $name | cut -c2-)
+ if [ "$NAME" = "ata" ]; then
+ SET="$SET $(cat $MBD_DIR/lib/modules/$kernel/modules.block |egrep '(ata|ahci)' |sed -e 's/.ko//')"
+ elif [ "$NAME" = "scsi" ]; then
+ SET="$SET $(cat $MBD_DIR/lib/modules/$kernel/modules.block) |sed -e 's/.ko//')"
+ else
# Ignore if group list does not exist
if [ -e $MBD_DIR/lib/modules/$kernel/modules.$NAME ]; then
- SET="$SET $(cat $MBD_DIR/lib/modules/$kernel/modules.$NAME |sed -e 's/.ko//')"
+ SET="$SET $(cat $MBD_DIR/lib/modules/$kernel/modules.$NAME |sed -e 's/.ko//')"
fi
- fi
- else
- SET="$SET $name"
- fi
+ fi
+ else
+ SET="$SET $name"
+ fi
done
echo $SET
@@ -309,44 +298,44 @@ makemoduletree() {
case $module in
ipw2100)
cp $KERNELROOT/lib/firmware/ipw2100* $MBD_DIR/firmware
- ;;
+ ;;
ipw2200)
cp $KERNELROOT/lib/firmware/ipw2200* $MBD_DIR/firmware
- ;;
+ ;;
iwl3945)
cp $KERNELROOT/lib/firmware/iwlwifi-3945* $MBD_DIR/firmware
- ;;
+ ;;
iwl4965)
cp $KERNELROOT/lib/firmware/iwlwifi-4965* $MBD_DIR/firmware
- ;;
+ ;;
iwl5000)
cp $KERNELROOT/lib/firmware/iwlwifi-5000* $MBD_DIR/firmware
- ;;
+ ;;
atmel)
cp $KERNELROOT/lib/firmware/atmel_*.bin $MBD_DIR/firmware
- ;;
+ ;;
zd1211rw)
cp -r $KERNELROOT/lib/firmware/zd1211 $MBD_DIR/firmware
- ;;
+ ;;
qla2xxx)
cp $KERNELROOT/lib/firmware/ql* $MBD_DIR/firmware
- ;;
+ ;;
esac
done
# clean up leftover cruft
find -H $MMB_DIR/lib/modules -type d -exec rmdir -f {} \; 2>/dev/null
$MODLIST --modinfo-file $MODINFO --ignore-missing --modinfo \
- $MMB_MODULESET > $MMB_DIR/lib/modules/module-info
+ $MMB_MODULESET > $MMB_DIR/lib/modules/module-info
# compress modules
find -H $MMB_DIR/lib/modules -type f -name *.ko -exec gzip -9 {} \;
rundepmod $MMB_DIR
rm -f $MMB_DIR/lib/modules/*/modules.*map
rm -f $MMB_DIR/lib/modules/*/{build,source}
-
+
# create the pci.ids, from modules.alias and the X driver aliases
awk '!/^(\t\t|#)/ { print ;if ($0 == "ffff Illegal Vendor ID") nextfile; }' < $PCIIDS | \
- $TRIMPCIIDS $MMB_DIR/lib/modules/*/modules.alias $XDRIVERS/* > ../pci.ids
+ $TRIMPCIIDS $MMB_DIR/lib/modules/*/modules.alias $XDRIVERS/* > ../pci.ids
}
@@ -358,7 +347,7 @@ makeproductfile() {
echo $PRODUCT >> $root/.buildstamp
echo $VERSION >> $root/.buildstamp
if [ -n "$BUGURL" ]; then
- echo $BUGURL >> $root/.buildstamp
+ echo $BUGURL >> $root/.buildstamp
fi
}
@@ -372,6 +361,7 @@ instbin() {
get_dso_deps $ROOT "$BIN"
local DEPS="$DSO_DEPS"
mkdir -p $DIR/$LIBDIR
+
for x in $DEPS ; do
cp -Lfp $ROOT/$x $DIR/$LIBDIR
done
@@ -399,9 +389,9 @@ setupShellEnvironment() {
# PAM configuration
for i in pam_limits.so pam_env.so pam_unix.so pam_deny.so; do
- cp -f $IMGPATH/$LIBDIR/security/$i $MBD_DIR/$LIBDIR/security
+ cp -f $IMGPATH/$LIBDIR/security/$i $MBD_DIR/$LIBDIR/security
done
-
+
cp -f $IMGPATH/etc/pam.d/other $MBD_DIR/etc/pam.d
cat > $MBD_DIR/etc/pam.d/login << EOF
#%PAM-1.0
@@ -438,7 +428,6 @@ EOF
chmod 600 ssh_host_key ssh_host_rsa_key ssh_host_dsa_key; \
chmod 644 ssh_host_key.pub ssh_host_rsa_key.pub ssh_host_dsa_key.pub; )
-
cat > $MBD_DIR/etc/ssh/sshd_config <<EOF
Port 22
HostKey /etc/ssh/ssh_host_key
@@ -464,21 +453,21 @@ EOF
instbin $IMGPATH /usr/bin/login $MBD_DIR /sbin/login
instbin $IMGPATH /usr/sbin/sshd $MBD_DIR /sbin/sshd
instbin $IMGPATH /usr/bin/busybox $MBD_DIR /sbin/busybox
-
+
# make some symlinks
(cd $MBD_DIR/sbin;
- set $(./busybox 2>&1| awk '/^\t([[:alnum:]_\.\[]+,)+/' | sed 's/,//g' | sed 's/ +//');
- while [ -n "$1" ]; do
- if [ $1 != "busybox" -a $1 != "sh" ]; then
- # if file doesnt already exist, link to busybox
- if [ ! -f "$1" ]; then
- ln -sf ./busybox $1
- else
- [ -n "$DEBUG" ] && echo "Overriding busybox version of $1"
- fi
- fi
- shift
- done )
+ set $(./busybox 2>&1| awk '/^\t([[:alnum:]_\.\[]+,)+/' | sed 's/,//g' | sed 's/ +//');
+ while [ -n "$1" ]; do
+ if [ $1 != "busybox" -a $1 != "sh" ]; then
+ # if file doesnt already exist, link to busybox
+ if [ ! -f "$1" ]; then
+ ln -sf ./busybox $1
+ else
+ [ -n "$DEBUG" ] && echo "Overriding busybox version of $1"
+ fi
+ fi
+ shift
+ done )
}
@@ -492,40 +481,40 @@ makeinitrd() {
MYLANGTABLE=$LANGTABLE
MYLOADERTR=loader.tr
while [ x$(echo $1 | cut -c1-2) = x"--" ]; do
- if [ $1 = "--initrdto" ]; then
- EXTRAINITRDPATH=$2
- shift; shift
- continue
- elif [ $1 = "--keep" ]; then
- KEEP=yes
- shift
- continue
- elif [ $1 = "--initrdsize" ]; then
- INITRDSIZE=$2
- shift; shift
- continue
- elif [ $1 = "--loaderbin" ]; then
- LOADERBIN=$2
- shift; shift
- continue
- elif [ $1 = "--modules" ]; then
- INITRDMODULES=$2
- shift; shift
- continue
- fi
- echo "Unknown option passed to makeinitrd"
- exit 1
+ if [ $1 = "--initrdto" ]; then
+ EXTRAINITRDPATH=$2
+ shift; shift
+ continue
+ elif [ $1 = "--keep" ]; then
+ KEEP=yes
+ shift
+ continue
+ elif [ $1 = "--initrdsize" ]; then
+ INITRDSIZE=$2
+ shift; shift
+ continue
+ elif [ $1 = "--loaderbin" ]; then
+ LOADERBIN=$2
+ shift; shift
+ continue
+ elif [ $1 = "--modules" ]; then
+ INITRDMODULES=$2
+ shift; shift
+ continue
+ fi
+ echo "Unknown option passed to makeinitrd"
+ exit 1
done
if [ -z "$LOADERBIN" ]; then
- echo "no loader binary specified!" >&2
- exit 1
+ echo "no loader binary specified!" >&2
+ exit 1
fi
if [ -z "$INITRDMODULES" ]; then
- echo "warning: no loader modules specified!" >&2
+ echo "warning: no loader modules specified!" >&2
fi
if [ -z "$INITRDSIZE" ]; then
- echo "I don't know how big to make the initrd image!" >&2
- exit 1
+ echo "I don't know how big to make the initrd image!" >&2
+ exit 1
fi
MBD_DIR=$TMPDIR/makebootdisk.dir.$$
@@ -571,17 +560,17 @@ makeinitrd() {
mkdir -p $MBD_DIR/var/run/wpa_supplicant
if [ "$BUILDARCH" = "s390" -o "$BUILDARCH" = "s390x" ]; then
- mkdir -m 111 -p $MBD_DIR/var/empty/sshd
- mkdir -p $MBD_DIR/etc/{pam.d,security}
- mkdir -p $MBD_DIR/$LIBDIR/security
- cp $IMGPATH/$LIBDIR/libpam_misc.so.0.* $MBD_DIR/$LIBDIR/libpam_misc.so.0
- ln -s /tmp $MBD_DIR/var/state/xkb
- cp $IMGPATH/usr/bin/xauth $MBD_DIR/sbin/xauth
+ mkdir -m 111 -p $MBD_DIR/var/empty/sshd
+ mkdir -p $MBD_DIR/etc/{pam.d,security}
+ mkdir -p $MBD_DIR/$LIBDIR/security
+ cp $IMGPATH/$LIBDIR/libpam_misc.so.0.* $MBD_DIR/$LIBDIR/libpam_misc.so.0
+ ln -s /tmp $MBD_DIR/var/state/xkb
+ cp $IMGPATH/usr/bin/xauth $MBD_DIR/sbin/xauth
cp $IMGPATH/usr/sbin/cmsfs* $MBD_DIR/sbin/
fi
if [ -n "$INITRDMODULES" ]; then
- MODSET=`expandModuleSet "$INITRDMODULES"`
+ MODSET=`expandModuleSet "$INITRDMODULES"`
makemoduletree $MBD_DIR "$MODSET"
fi
@@ -592,19 +581,20 @@ makeinitrd() {
instbin $IMGPATH ${LOADERBINDIR##$IMGPATH}/$LOADERBIN $MBD_DIR /sbin/loader
if [ "$BUILDARCH" != "s390" -a "$BUILDARCH" != "s390x" ]; then
instbin $IMGPATH ${LOADERBINDIR##$IMGPATH}/init $MBD_DIR /sbin/init
- ln -s ./init $MBD_DIR/sbin/reboot
- ln -s ./init $MBD_DIR/sbin/halt
- ln -s ./init $MBD_DIR/sbin/poweroff
+ ln -s ./init $MBD_DIR/sbin/reboot
+ ln -s ./init $MBD_DIR/sbin/halt
+ ln -s ./init $MBD_DIR/sbin/poweroff
else
- instbin $IMGPATH ${LOADERBINDIR##IMGPATH}/shutdown $MBD_DIR /sbin/shutdown
- instbin $IMGPATH /usr/lib/anaconda-runtime/loader/linuxrc.s390 $MBD_DIR /sbin/init
- instbin $IMGPATH /usr/sbin/dasdfmt $MBD_DIR /sbin/dasdfmt
+ instbin $IMGPATH ${LOADERBINDIR##IMGPATH}/shutdown $MBD_DIR /sbin/shutdown
+ instbin $IMGPATH /usr/lib/anaconda-runtime/loader/linuxrc.s390 $MBD_DIR /sbin/init
+ instbin $IMGPATH /usr/sbin/dasdfmt $MBD_DIR /sbin/dasdfmt
fi
if [ "$BUILDARCH" != "s390" -a "$BUILDARCH" != "s390x" ]; then
install -m 644 $KEYMAPS $MBD_DIR/etc/keymaps.gz
install -m 644 $SCREENFONT $MBD_DIR/etc/screenfont.gz
fi
+
install -m 644 $MYLANGTABLE $MBD_DIR/etc/lang-table
install -m 644 $IMGPATH/etc/passwd $MBD_DIR/etc/passwd
install -m 644 $IMGPATH/etc/group $MBD_DIR/etc/group
@@ -736,14 +726,14 @@ makeinitrd() {
install -m 644 $LOADERBINDIR/$MYLOADERTR $MBD_DIR/etc/loader.tr
for i in a/ansi d/dumb l/linux s/screen v/vt100 v/vt100-nav v/vt102 x/xterm x/xterm-color g/gnome ; do
- [ -f $IMGPATH/usr/share/terminfo/$i ] && \
- install -m 644 $IMGPATH/usr/share/terminfo/$i $MBD_DIR/etc/terminfo/$i
+ [ -f $IMGPATH/usr/share/terminfo/$i ] && \
+ install -m 644 $IMGPATH/usr/share/terminfo/$i $MBD_DIR/etc/terminfo/$i
done
makeproductfile $MBD_DIR
for n in insmod rmmod modprobe; do
- instbin $IMGPATH /usr/sbin/$n $MBD_DIR /sbin/$n
+ instbin $IMGPATH /usr/sbin/$n $MBD_DIR /sbin/$n
done
ln -s /sbin/init $MBD_DIR/init
@@ -754,7 +744,7 @@ makeinitrd() {
# s390/s390x need sshd setup
if [ "$BUILDARCH" = "s390" -o "$BUILDARCH" = "s390x" ]; then
- setupShellEnvironment
+ setupShellEnvironment
fi
cat > $MBD_DIR/.profile <<EOF
@@ -770,12 +760,12 @@ EOF
echo "Wrote $MBD_FSIMAGE (${size}k compressed)"
if [ -n "$EXTRAINITRDPATH" ]; then
- mkdir -p `dirname $EXTRAINITRDPATH`
- cp -a $MBD_FSIMAGE $EXTRAINITRDPATH
+ mkdir -p `dirname $EXTRAINITRDPATH`
+ cp -a $MBD_FSIMAGE $EXTRAINITRDPATH
fi
if [ -z "$KEEP" ]; then
- rm -rf $MBD_FSIMAGE $MBD_BOOTTREE
+ rm -rf $MBD_FSIMAGE $MBD_BOOTTREE
fi
}
@@ -791,7 +781,7 @@ makeinstimage () {
(cd $IMGPATH; find . | cpio --quiet -p $tmp)
makeproductfile $tmp
- if [ -z "$type" -o "$type" = "cramfs" ]; then
+ if [ -z "$type" -o "$type" = "cramfs" ]; then
echo "Running mkcramfs $CRAMBS $tmp $INSTIMGPATH/${imagename}2.img"
mkfs.cramfs $CRAMBS $tmp $TMPDIR/${imagename}2.img.$$
elif [ "$type" = "squashfs" ]; then
@@ -813,29 +803,29 @@ makemainimage () {
type=$2
mmi_tmpimage=$TMPDIR/instimage.img.$$
mmi_mntpoint=$TMPDIR/instimage.mnt.$$
-
+
rm -rf $mmi_tmpimage $mmi_mntpoint
mkdir $mmi_mntpoint
if [ $type = "ext2" ]; then
SIZE=$(du -sk $IMGPATH | awk '{ print int($1 * 1.1) }')
if [ -d $IMGPATH/usr/lib/anaconda-runtime ]; then
- ERROR=$(du -sk $IMGPATH/usr/lib/anaconda-runtime | awk '{ print $1 }')
- SIZE=$(expr $SIZE - $ERROR)
+ ERROR=$(du -sk $IMGPATH/usr/lib/anaconda-runtime | awk '{ print $1 }')
+ SIZE=$(expr $SIZE - $ERROR)
fi
if [ -d $IMGPATH/usr/lib/syslinux ]; then
- ERROR=$(du -sk $IMGPATH/usr/lib/syslinux | awk '{ print $1 }')
- SIZE=$(expr $SIZE - $ERROR)
+ ERROR=$(du -sk $IMGPATH/usr/lib/syslinux | awk '{ print $1 }')
+ SIZE=$(expr $SIZE - $ERROR)
fi
dd if=/dev/zero bs=1k count=${SIZE} of=$mmi_tmpimage 2>/dev/null
- mke2fs -q -F $mmi_tmpimage > /dev/null
+ mke2fs -q -F $mmi_tmpimage > /dev/null
tune2fs -c0 -i0 $mmi_tmpimage >/dev/null
mount -o loop $mmi_tmpimage $mmi_mntpoint
(cd $IMGPATH; find . |
- fgrep -v "./usr/lib/anaconda-runtime" |
- fgrep -v "./usr/lib/syslinux"
- cpio -H crc -o) | (cd $mmi_mntpoint; cpio -iumd)
+ fgrep -v "./usr/lib/anaconda-runtime" |
+ fgrep -v "./usr/lib/syslinux"
+ cpio -H crc -o) | (cd $mmi_mntpoint; cpio -iumd)
makeproductfile $mmi_mntpoint
umount $mmi_mntpoint
rmdir $mmi_mntpoint
@@ -851,14 +841,14 @@ makemainimage () {
mkfs.cramfs $CRAMBS $IMGPATH $mmi_tmpimage
SIZE=$(expr `cat $mmi_tmpimage | wc -c` / 1024)
fi
-
+
cp $mmi_tmpimage $INSTIMGPATH/${imagename}.img
chmod 644 $INSTIMGPATH/${imagename}.img
echo "Wrote $INSTIMGPATH/${imagename}.img (${SIZE}k)"
relpath=${INSTIMGPATH#$TOPDESTPATH/}
echo "mainimage = ${relpath}/${imagename}.img" >> $TOPDESTPATH/.treeinfo
-
+
rm $mmi_tmpimage
}
@@ -886,7 +876,7 @@ if [ ${BUILDARCH} = s390x ]; then
source $TOPDIR/mk-images.s390
elif [ ${BUILDARCH} = ppc64 ]; then
# ... and similar for ppc64
- source $TOPDIR/mk-images.ppc
+ source $TOPDIR/mk-images.ppc
elif [ ${BUILDARCH} = "x86_64" -o ${BUILDARCH} = "i386" ]; then
source $TOPDIR/mk-images.x86
source $TOPDIR/mk-images.efi
@@ -915,70 +905,74 @@ fi
foundakernel=""
for KERNELARCH in $arches; do
- for kernelvers in $kerneltags; do
- kpackage=$(findPackage $kernelvers)
- if [ "$KERNELARCH" = "i586" -a -z "$kpackage" ]; then
- echo "No i586 kernel, trying i686..."
- KERNELARCH="i686"
- kpackage=$(findPackage $kernelvers)
- fi
-
- if [ -z "$kpackage" ]; then
- echo "Unable to find kernel package $kernelvers"
- continue
- fi
+ for kernelvers in $kerneltags; do
+ kpackage=$(findPackage $kernelvers)
+ if [ "$KERNELARCH" = "i586" -a -z "$kpackage" ]; then
+ echo "No i586 kernel, trying i686..."
+ KERNELARCH="i686"
+ kpackage=$(findPackage $kernelvers)
+ fi
- yumdownloader -c $yumconf --archlist=$KERNELARCH $kpackage
- kpackage="$kpackage.rpm"
- if [ ! -f "$kpackage" ]; then
- echo "kernel ($kernelvers) doesn't exist for $KERNELARCH. skipping"
- continue
- fi
+ if [ -z "$kpackage" ]; then
+ echo "Unable to find kernel package $kernelvers"
+ continue
+ fi
- KERNELROOT=$KERNELBASE/$KERNELARCH
- mkdir -p $KERNELROOT
+ yumdownloader -c $yumconf --archlist=$KERNELARCH $kpackage
+ kpackage="$kpackage.rpm"
+ if [ ! -f "$kpackage" ]; then
+ echo "kernel ($kernelvers) doesn't exist for $KERNELARCH. skipping"
+ continue
+ fi
- foundakernel="yes"
+ KERNELROOT=$KERNELBASE/$KERNELARCH
+ mkdir -p $KERNELROOT
- if [ "$BUILDARCH" = "ia64" ]; then
- vmlinuz=$(rpm --nodigest --nosignature -qpl $kpackage |grep ^/boot/efi/EFI/redhat/vmlinuz | head -n 1)
- version=${vmlinuz##/boot/efi/EFI/redhat/vmlinuz-}
- else
- vmlinuz=$(rpm --nodigest --nosignature -qpl $kpackage |grep ^/boot/vmlinuz | head -n 1)
- version=${vmlinuz##/boot/vmlinuz-}
- fi
- arch=$(rpm --nodigest --nosignature --qf '%{ARCH}\n' -qp $kpackage)
+ foundakernel="yes"
- rpm2cpio $kpackage | (cd $KERNELROOT; cpio --quiet -iumd)
- rm -f $kpackage
- # expand out any available firmware too
- for p in $(repoquery -c $yumconf '*firmware*') ; do yumdownloader -c $yumconf $p ; rpm2cpio *firmware*.rpm | (cd $KERNELROOT; cpio --quiet -iumd) ; rm -f *firmware*.rpm ; done
+ if [ "$BUILDARCH" = "ia64" ]; then
+ vmlinuz=$(rpm --nodigest --nosignature -qpl $kpackage |grep ^/boot/efi/EFI/redhat/vmlinuz | head -n 1)
+ version=${vmlinuz##/boot/efi/EFI/redhat/vmlinuz-}
+ else
+ vmlinuz=$(rpm --nodigest --nosignature -qpl $kpackage |grep ^/boot/vmlinuz | head -n 1)
+ version=${vmlinuz##/boot/vmlinuz-}
+ fi
+ arch=$(rpm --nodigest --nosignature --qf '%{ARCH}\n' -qp $kpackage)
+
+ rpm2cpio $kpackage | (cd $KERNELROOT; cpio --quiet -iumd)
+ rm -f $kpackage
+ # expand out any available firmware too
+ for p in $(repoquery -c $yumconf '*firmware*') ; do
+ yumdownloader -c $yumconf $p
+ rpm2cpio *firmware*.rpm | (cd $KERNELROOT; cpio --quiet -iumd)
+ rm -f *firmware*.rpm
+ done
- if [ ! -d "$KERNELROOT/lib/modules/$version" ]; then
- echo "$KERNELROOT/lib/modules/$version is not a valid modules directory" 2>&1
- exit 1
- fi
+ if [ ! -d "$KERNELROOT/lib/modules/$version" ]; then
+ echo "$KERNELROOT/lib/modules/$version is not a valid modules directory" 2>&1
+ exit 1
+ fi
- if [ ! -f "$KERNELROOT/$KERNELDIR/${KERNELNAME}-$version" ]; then
- echo "$KERNELROOT/$KERNELDIR/${KERNELNAME}-$version does not exist"
- exit 1
- fi
+ if [ ! -f "$KERNELROOT/$KERNELDIR/${KERNELNAME}-$version" ]; then
+ echo "$KERNELROOT/$KERNELDIR/${KERNELNAME}-$version does not exist"
+ exit 1
+ fi
- allmods=$(find $KERNELROOT/lib/modules/$version -name *.ko)
+ allmods=$(find $KERNELROOT/lib/modules/$version -name *.ko)
- rundepmod $KERNELROOT
- $GENMODINFO $KERNELROOT/lib/modules/$version > $MODINFO
+ rundepmod $KERNELROOT
+ $GENMODINFO $KERNELROOT/lib/modules/$version > $MODINFO
- # make the boot images
- makeBootImages
+ # make the boot images
+ makeBootImages
- makeEfiImages $yumconf
- done
+ makeEfiImages $yumconf
+ done
done
if [ -n "$foundakernel" ]; then
- makeSecondStage
- rm -rf $KERNELBASE
+ makeSecondStage
+ rm -rf $KERNELBASE
fi
doPostImages
--
1.6.0.6
>From c97837cf01ccb9af11a80fb49ec778e907c8e3a0 Mon Sep 17 00:00:00 2001
From: Jeroen van Meeuwen (Fedora Unity) <kanarip@xxxxxxxxxxxxxxx>
Date: Sun, 11 Jan 2009 18:40:59 -0500
Subject: [PATCH] Fix indentation in upd-instroot
---
scripts/upd-instroot | 224 ++++++++++++++++++++++++--------------------------
1 files changed, 109 insertions(+), 115 deletions(-)
diff --git a/scripts/upd-instroot b/scripts/upd-instroot
index b7bef0e..e1bb45a 100755
--- a/scripts/upd-instroot
+++ b/scripts/upd-instroot
@@ -24,54 +24,47 @@ ARCH=`uname -m`
while [ $# -gt 0 ]; do
case $1 in
- --debug)
- DEBUG="--debug"
- shift
- ;;
-
- --arch)
- ARCH=$2
- shift; shift
- ;;
-
- --imgdir)
- DEST=$2
- shift; shift
- ;;
-
- # a filesystem tree to use as updates. could be the output
- # of 'make install' from anaconda...
- --updates)
- UPDATES=$2
- shift; shift
- ;;
-
- --nogr)
- echo "*** DeprecationWarning: ignoring --nogr option." >&2
- shift
- ;;
-
- --mindir)
- echo "*** DeprecationWarning: ignoring --mindir option." >&2
- shift; shift
- ;;
-
- --stg2dir)
- echo "*** DeprecationWarning: please use --imgdir instead of --stg2dir." >&2
- shift; shift
- ;;
-
- *)
- yumconf=$1
- shift
- ;;
+ --debug)
+ DEBUG="--debug"
+ shift
+ ;;
+ --arch)
+ ARCH=$2
+ shift; shift
+ ;;
+ --imgdir)
+ DEST=$2
+ shift; shift
+ ;;
+ # a filesystem tree to use as updates. could be the output
+ # of 'make install' from anaconda...
+ --updates)
+ UPDATES=$2
+ shift; shift
+ ;;
+ --nogr)
+ echo "*** DeprecationWarning: ignoring --nogr option." >&2
+ shift
+ ;;
+ --mindir)
+ echo "*** DeprecationWarning: ignoring --mindir option." >&2
+ shift; shift
+ ;;
+ --stg2dir)
+ echo "*** DeprecationWarning: please use --imgdir instead of --stg2dir." >&2
+ shift; shift
+ ;;
+ *)
+ yumconf=$1
+ shift
+ ;;
esac
done
if [ -z "$yumconf" ]; then
- echo "upd-instroot: updates instimage from a Red Hat RPMS directory"
- echo "usage: $0 [--debug] [--arch arch] [--imgdir imgdir] [yumconf]"
- exit 1
+ echo "upd-instroot: updates instimage from a Red Hat RPMS directory"
+ echo "usage: $0 [--debug] [--arch arch] [--imgdir imgdir] [yumconf]"
+ exit 1
fi
if [ $ARCH = x86_64 -o $ARCH = s390x -o $ARCH = ppc64 ]; then
@@ -99,45 +92,46 @@ expandPackageSet() {
KEEPFILES=$5
[ -d $PKGDEST ] || die "ERROR: directory missing: $PKGDEST"
- if [ -z "$DEBUG" ]; then outlvl="--quiet" ; else outlvl="--verbose"; fi
+ [ -z "$DEBUG" ] && outlvl="--quiet" || outlvl="--verbose"
+
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)
+ (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')
- echo "usr/share/themes/$gtktheme" >> $KEEPFILES
- # find gtk engine needed
- for engine in `grep engine $YUMDIR/usr/share/themes/$gtktheme/gtk-2.0/gtkrc | awk {'print $2;'} | sed -e 's/"//g' | sort -u` ; do
- echo "usr/$LIBDIR/gtk-2.0/*/engines/*$engine*" >> $KEEPFILES
- done
-
- theme=$(grep "gtk-icon-theme-name" $YUMDIR/etc/gtk-2.0/gtkrc | awk {'print $3;'} | sed -e 's/"//g')
- while [ -n "$theme" ]; do
- echo "usr/share/icons/$theme" >> $KEEPFILES
- theme=$(grep Inherits $YUMDIR/usr/share/icons/$theme/index.theme | cut -d = -f 2)
- done
+ gtktheme=$(grep "gtk-theme-name" $YUMDIR/etc/gtk-2.0/gtkrc | awk {'print $3;'} | sed -e 's/"//g')
+ echo "usr/share/themes/$gtktheme" >> $KEEPFILES
+ # find gtk engine needed
+ for engine in `grep engine $YUMDIR/usr/share/themes/$gtktheme/gtk-2.0/gtkrc | awk {'print $2;'} | sed -e 's/"//g' | sort -u` ; do
+ echo "usr/$LIBDIR/gtk-2.0/*/engines/*$engine*" >> $KEEPFILES
+ done
+
+ theme=$(grep "gtk-icon-theme-name" $YUMDIR/etc/gtk-2.0/gtkrc | awk {'print $3;'} | sed -e 's/"//g')
+ while [ -n "$theme" ]; do
+ echo "usr/share/icons/$theme" >> $KEEPFILES
+ theme=$(grep Inherits $YUMDIR/usr/share/icons/$theme/index.theme | cut -d = -f 2)
+ done
fi
echo `date` "Installing files"
pushd $YUMDIR >/dev/null
cat $KEEPFILES | while read spec ; do
- #Pull off path
- path=`echo "$spec" | sed 's,\([^[*\?]*\)/.*,\1,'`
- for filespec in `find ./$path -path "./$spec" 2> /dev/null` ; do
- if [ ! -e $filespec ]; then
- continue
- elif [ ! -d $filespec ]; then
- instFile $filespec $PKGDEST
- else
- for i in `find $filespec -type f 2> /dev/null` ; do instFile $i $PKGDEST ; done
- for i in `find $filespec -type l 2> /dev/null` ; do instFile $i $PKGDEST ; done
- for d in `find $filespec -type d 2> /dev/null` ; do instDir $d $PKGDEST ; done
- fi
- done
+ #Pull off path
+ path=`echo "$spec" | sed 's,\([^[*\?]*\)/.*,\1,'`
+ for filespec in `find ./$path -path "./$spec" 2> /dev/null` ; do
+ if [ ! -e $filespec ]; then
+ continue
+ elif [ ! -d $filespec ]; then
+ instFile $filespec $PKGDEST
+ else
+ for i in `find $filespec -type f 2> /dev/null` ; do instFile $i $PKGDEST ; done
+ for i in `find $filespec -type l 2> /dev/null` ; do instFile $i $PKGDEST ; done
+ for d in `find $filespec -type d 2> /dev/null` ; do instDir $d $PKGDEST ; done
+ fi
+ done
done
popd >/dev/null
}
@@ -149,42 +143,42 @@ die () {
}
PACKAGES="GConf2 NetworkManager ORBit2 PolicyKit VLGothic-fonts acl anaconda
- anaconda-yum-plugins at-spi atk attr audit-libs bash bitmap-fonts-cjk
- booty busybox-anaconda bzip2 bzip2-libs cairo cjkunifonts-uming
- comps-extras coreutils cpio cracklib cracklib-dicts cracklib-python
- cryptsetup-luks db4 dbus dbus-python dejavu-fonts device-mapper
- device-mapper-libs dhclient dhcpv6-client dmapi dmraid dmraid-libs
- dogtail dosfstools e2fsprogs e2fsprogs-libs echo-icon-theme
- elfutils-libelf expat firstboot fontconfig fonts-ISO8859-2 freetype gail
- gdk-pixbuf gfs2-utils glib2 glibc-common gnome-python2-canvas gnome-python2-gconf
- gnome-python2-gtkhtml2 gnome-themes gpm gtk2 gtk2-engines gtkhtml2 hal
- hdparm hwdata initscripts iproute iputils iscsi-initiator-utils
- jfsutils keyutils-libs krb5-libs libICE libSM libX11 libXau
- libXaw libXcursor libXdmcp libXevie libXext libXfixes libXfont libXft
- libXi libXinerama libXmu libXpm libXrandr libXrender libXt libXtst
- libXxf86misc libacl libart_lgpl libattr libbdevid libbdevid-python
- libbonobo libfontenc libgcc
- libglade2 libgnomecanvas libgcrypt libgpg-error libjpeg liblbxutil libnl
- libpixman libpng libselinux libselinux-python libsemanage
- libsemanage-python libsepol libstdc++ libtermcap libthai libuser
- libuser-python libvolume_id libxcb libxkbfile libxml2 lohit-fonts-bengali
- lohit-fonts-gujarati lohit-fonts-hindi lohit-fonts-kannada lohit-fonts-oriya
- lohit-fonts-punjabi lohit-fonts-tamil lohit-fonts-telugu lvm2 mdadm
- mesa-dri-drivers mkinitrd module-init-tools nash ncurses neon net-tools
- newt newt-python nfs-utils nspr nss pam pango parted pciutils pcre
- policy policycoreutils popt prelink procps pycairo pygobject2 pygtk2
- pygtk2-libglade pykickstart pyparted pyspi python python-bugzilla
- python-elementtree python-libs python-pyblock python-sqlite
- python-urlgrabber pyxf86config raidtools readline redhat-artwork
- reiserfs-utils rhpl rpm rpm-libs rpm-python sed selinux-policy-targeted
- setup slang smc-fonts-meera specspo sqlite synaptics system-config-date
- system-config-keyboard system-logos system-release taipeifonts tcp_wrappers
- tzdata udev un-core-fonts-dotum urw-fonts util-linux-ng vnc-libs vnc-server
- wpa_supplicant xkeyboard-config xfsdump xfsprogs xorg-x11 xorg-x11-auth
- xorg-x11-base xorg-x11-drivers xorg-x11-font-utils xorg-x11-fonts-ethiopic
- xorg-x11-fonts-misc xorg-x11-libs xorg-x11-libs-data xorg-x11-server-utils
- xorg-x11-server-Xorg xorg-x11-xkb-utils xorg-x11-xkbdata xorg-x11-xfs yum
- yum-fedorakmod yum-metadata-parser zenity zlib /etc/gtk-2.0/gtkrc"
+ anaconda-yum-plugins at-spi atk attr audit-libs bash bitmap-fonts-cjk
+ booty busybox-anaconda bzip2 bzip2-libs cairo cjkunifonts-uming
+ comps-extras coreutils cpio cracklib cracklib-dicts cracklib-python
+ cryptsetup-luks db4 dbus dbus-python dejavu-fonts device-mapper
+ device-mapper-libs dhclient dhcpv6-client dmapi dmraid dmraid-libs
+ dogtail dosfstools e2fsprogs e2fsprogs-libs echo-icon-theme
+ elfutils-libelf expat firstboot fontconfig fonts-ISO8859-2 freetype gail
+ gdk-pixbuf gfs2-utils glib2 glibc-common gnome-python2-canvas gnome-python2-gconf
+ gnome-python2-gtkhtml2 gnome-themes gpm gtk2 gtk2-engines gtkhtml2 hal
+ hdparm hwdata initscripts iproute iputils iscsi-initiator-utils
+ jfsutils keyutils-libs krb5-libs libICE libSM libX11 libXau
+ libXaw libXcursor libXdmcp libXevie libXext libXfixes libXfont libXft
+ libXi libXinerama libXmu libXpm libXrandr libXrender libXt libXtst
+ libXxf86misc libacl libart_lgpl libattr libbdevid libbdevid-python
+ libbonobo libfontenc libgcc
+ libglade2 libgnomecanvas libgcrypt libgpg-error libjpeg liblbxutil libnl
+ libpixman libpng libselinux libselinux-python libsemanage
+ libsemanage-python libsepol libstdc++ libtermcap libthai libuser
+ libuser-python libvolume_id libxcb libxkbfile libxml2 lohit-fonts-bengali
+ lohit-fonts-gujarati lohit-fonts-hindi lohit-fonts-kannada lohit-fonts-oriya
+ lohit-fonts-punjabi lohit-fonts-tamil lohit-fonts-telugu lvm2 mdadm
+ mesa-dri-drivers mkinitrd module-init-tools nash ncurses neon net-tools
+ newt newt-python nfs-utils nspr nss pam pango parted pciutils pcre
+ policy policycoreutils popt prelink procps pycairo pygobject2 pygtk2
+ pygtk2-libglade pykickstart pyparted pyspi python python-bugzilla
+ python-elementtree python-libs python-pyblock python-sqlite
+ python-urlgrabber pyxf86config raidtools readline redhat-artwork
+ reiserfs-utils rhpl rpm rpm-libs rpm-python sed selinux-policy-targeted
+ setup slang smc-fonts-meera specspo sqlite synaptics system-config-date
+ system-config-keyboard system-logos system-release taipeifonts tcp_wrappers
+ tzdata udev un-core-fonts-dotum urw-fonts util-linux-ng vnc-libs vnc-server
+ wpa_supplicant xkeyboard-config xfsdump xfsprogs xorg-x11 xorg-x11-auth
+ xorg-x11-base xorg-x11-drivers xorg-x11-font-utils xorg-x11-fonts-ethiopic
+ xorg-x11-fonts-misc xorg-x11-libs xorg-x11-libs-data xorg-x11-server-utils
+ xorg-x11-server-Xorg xorg-x11-xkb-utils xorg-x11-xkbdata xorg-x11-xfs yum
+ yum-fedorakmod yum-metadata-parser zenity zlib /etc/gtk-2.0/gtkrc"
if [ $ARCH = i386 ]; then
PACKAGES="$PACKAGES glibc.i386 openssl.i386"
@@ -208,7 +202,7 @@ fi
if [ $ARCH = s390 -o $ARCH = s390x ]; then
PACKAGES="$PACKAGES s390utils binutils libgcc tcp_wrappers
sed net-tools openssh openssh-server coreutils
- login initscripts bash portmap pam
+ login initscripts bash portmap pam
login mount grep modutils gawk
strace xorg-x11-xauth xorg-x11-libs"
fi
@@ -684,7 +678,7 @@ EOF
# KEEPFILERESCUE is all files to keep from the packages in PACKAGESRESCUE
#
# This defines the files in addition to KEEPFILE that make up
-# the install images for NFS and CD/DVD based rescue mode installs. This
+# the install images for NFS and CD/DVD based rescue mode installs. This
# image is not loaded into memory so it can be considerably larger.
#
# NOTE: hd, ftp, and http rescue mode use and image based on KEEPFILE since
@@ -846,12 +840,12 @@ cat $DEST/usr/lib/anaconda/lang-table* | awk '
print $2;
}
' | sed -e 's/latn/Latn/g' | LC_ALL=C sort -u > $DEST/locales
-for p in lib share; do (
-cd $DEST/usr/$p/locale && {
-ls | grep -v locale.alias | grep -v locale-archive | LC_ALL=C sort > $DEST/locales.list
-LC_ALL=C comm -13 $DEST/locales $DEST/locales.list | xargs rm -rf
-}
-); done
+for p in lib share; do
+ (cd $DEST/usr/$p/locale && {
+ ls | grep -v locale.alias | grep -v locale-archive | LC_ALL=C sort > $DEST/locales.list
+ LC_ALL=C comm -13 $DEST/locales $DEST/locales.list | xargs rm -rf
+ })
+done
rm -f $DEST/locales $DEST/locales.list
# fixup joe links
--
1.6.0.6
>From fbcbc55903973a43f6ff92beb1538095c1466269 Mon Sep 17 00:00:00 2001
From: Jeroen van Meeuwen (Fedora Unity) <kanarip@xxxxxxxxxxxxxxx>
Date: Sun, 11 Jan 2009 19:50:26 -0500
Subject: [PATCH] Fix indentation in mk-images.efi
---
scripts/mk-images.efi | 106 +++++++++++++++++++++++++------------------------
1 files changed, 54 insertions(+), 52 deletions(-)
diff --git a/scripts/mk-images.efi b/scripts/mk-images.efi
index e669876..6e06a72 100644
--- a/scripts/mk-images.efi
+++ b/scripts/mk-images.efi
@@ -53,40 +53,40 @@ makeefibootimage() {
MBD_BOOTTREE=${TMPDIR:-/tmp}/makebootdisk.tree.$$
MBD_BOOTTREE_TMP=$MBD_BOOTTREE'_tmp'
while [ x$(echo $1 | cut -c1-2) = x"--" ]; do
- if [ $1 = "--kernel" ]; then
- KERNELFILE=$2
- shift; shift
- continue
- elif [ $1 = "--initrd" ]; then
- INITRDFILE=$2
- shift; shift
- continue
- elif [ $1 = "--imagename" ]; then
- MBD_FILENAME=$IMAGEPATH/$2
- shift; shift
- continue
- elif [ $1 = "--grubpkg" ]; then
- grubpkg=$2
- shift; shift
- continue
- fi
- echo "Unknown option passed to makebootdisk"
- exit 1
+ if [ $1 = "--kernel" ]; then
+ KERNELFILE=$2
+ shift; shift
+ continue
+ elif [ $1 = "--initrd" ]; then
+ INITRDFILE=$2
+ shift; shift
+ continue
+ elif [ $1 = "--imagename" ]; then
+ MBD_FILENAME=$IMAGEPATH/$2
+ shift; shift
+ continue
+ elif [ $1 = "--grubpkg" ]; then
+ grubpkg=$2
+ shift; shift
+ continue
+ fi
+ echo "Unknown option passed to makebootdisk"
+ exit 1
done
if [ -z "$MBD_FILENAME" ]; then
- echo "No imagename passed"
- exit 1
+ echo "No imagename passed"
+ exit 1
fi
if [ -z "$KERNELFILE" ]; then
- echo "No kernel file passed"
- exit 1
+ echo "No kernel file passed"
+ exit 1
fi
if [ -z "$INITRDFILE" ]; then
- echo "No initrd file passed"
- exit 1
+ echo "No initrd file passed"
+ exit 1
fi
MBD_FSIMAGE="$INITRDFILE"
@@ -104,14 +104,14 @@ makeefibootimage() {
umount $MBD_BOOTTREE
if [ -n "$EXTRAKERNELPATH" ]; then
- mkdir -p `dirname $EXTRAKERNELPATH`
- cp -f $KERNELROOT/$KERNELDIR/${KERNELNAME}-* $EXTRAKERNELPATH
+ mkdir -p `dirname $EXTRAKERNELPATH`
+ cp -f $KERNELROOT/$KERNELDIR/${KERNELNAME}-* $EXTRAKERNELPATH
fi
mkdir -p `dirname $MBD_FILENAME`
rm -rf $MBD_TMPIMAGE $MBD_MNTPOINT $MBD_BOOTTREE
if [ -z "$INITRDFILE" ]; then
- rm -f $MBD_FSIMAGE
+ rm -f $MBD_FSIMAGE
fi
chmod a+r $MBD_FILENAME
@@ -150,8 +150,8 @@ prepareEfiTree() {
# The first generation Mactel machines get the bootloader name wrong
# as per the spec. Awesome, guys.
if [ "$efiarch" == "ia32" ]; then
- cp $MBD_BOOTTREE_TMP/EFI/boot/grub.efi $MBD_BOOTTREE_TMP/EFI/boot/boot.efi
- cp $MBD_BOOTTREE_TMP/EFI/boot/grub.conf $MBD_BOOTTREE_TMP/EFI/boot/boot.conf
+ cp $MBD_BOOTTREE_TMP/EFI/boot/grub.efi $MBD_BOOTTREE_TMP/EFI/boot/boot.efi
+ cp $MBD_BOOTTREE_TMP/EFI/boot/grub.conf $MBD_BOOTTREE_TMP/EFI/boot/boot.conf
fi
mv $MBD_BOOTTREE_TMP/EFI/boot/grub.efi $MBD_BOOTTREE_TMP/EFI/boot/boot${efiarch}.efi
@@ -171,28 +171,30 @@ prepareEfiTree() {
makeEfiImages() {
yumconf="$1"
if [ "$kernelvers" != "$kernelxen" ]; then
- local grubarch=${efiarch}
- case ${efiarch} in
- ia32) grubarch=i386 ;;
- x64) grubarch=x86_64 ;;
- esac
- grubpkg=$(repoquery --qf "%{NAME}-%{VERSION}-%{RELEASE}.%{ARCH}" -c $yumconf grub.$grubarch)
- if [ -z "$grubpkg" ]; then
- echo "cannot find package grub.$grubarch" >&2
- return 1
- fi
- echo "Building efiboot.img for ${efiarch}/$KERNELARCH at $TOPDESTPATH/images/efiboot.img"
-
- makeefibootimage \
- --imagename pxeboot/efiboot.img \
- --kernel $TOPDESTPATH/images/pxeboot/vmlinuz \
- --initrd $TOPDESTPATH/images/pxeboot/initrd.img \
- --grubpkg ${grubpkg}
- local ret=$?
- [ $ret -eq 0 ] || return $ret
-
- makeefibootdisk $TOPDESTPATH/images/pxeboot/efiboot.img $TOPDESTPATH/images/efidisk.img
- return $?
+ local grubarch=${efiarch}
+ case ${efiarch} in
+ ia32) grubarch=i386 ;;
+ x64) grubarch=x86_64 ;;
+ esac
+
+ grubpkg=$(repoquery --qf "%{NAME}-%{VERSION}-%{RELEASE}.%{ARCH}" -c $yumconf grub.$grubarch)
+
+ if [ -z "$grubpkg" ]; then
+ echo "cannot find package grub.$grubarch" >&2
+ return 1
+ fi
+ echo "Building efiboot.img for ${efiarch}/$KERNELARCH at $TOPDESTPATH/images/efiboot.img"
+
+ makeefibootimage \
+ --imagename pxeboot/efiboot.img \
+ --kernel $TOPDESTPATH/images/pxeboot/vmlinuz \
+ --initrd $TOPDESTPATH/images/pxeboot/initrd.img \
+ --grubpkg ${grubpkg}
+ local ret=$?
+ [ $ret -eq 0 ] || return $ret
+
+ makeefibootdisk $TOPDESTPATH/images/pxeboot/efiboot.img $TOPDESTPATH/images/efidisk.img
+ return $?
fi
return 1
}
--
1.6.0.6
_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list