diff options
author | Richard W.M. Jones <rjones@redhat.com> | 2009-06-19 14:26:44 +0100 |
---|---|---|
committer | Richard W.M. Jones <rjones@redhat.com> | 2009-06-19 14:26:44 +0100 |
commit | 677b280411cd3596051f288eecb73b5d8ae23caa (patch) | |
tree | 4fe73a993767fb29b54a069fb519931f41289051 | |
parent | e395d7db8fd3fe3d1b121258fe2f401d6b3e64c8 (diff) | |
download | libguestfs-677b280411cd3596051f288eecb73b5d8ae23caa.tar.gz libguestfs-677b280411cd3596051f288eecb73b5d8ae23caa.tar.xz libguestfs-677b280411cd3596051f288eecb73b5d8ae23caa.zip |
Move distro package list to a separate packagelist.in file.
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | appliance/Makefile.am | 9 | ||||
-rwxr-xr-x | appliance/make.sh.in | 31 | ||||
-rw-r--r-- | appliance/packagelist.in | 28 |
4 files changed, 44 insertions, 25 deletions
@@ -25,6 +25,7 @@ appliance/initramfs.*.supermin.hostfiles appliance/kmod.whitelist appliance/libguestfs-supermin-helper appliance/make.sh +appliance/packagelist appliance/supermin-make.sh appliance/supermin-split.sh appliance/supermin.incfiles diff --git a/appliance/Makefile.am b/appliance/Makefile.am index 883bda56..4f5eeee0 100644 --- a/appliance/Makefile.am +++ b/appliance/Makefile.am @@ -19,7 +19,8 @@ EXTRA_DIST = \ make.sh update.sh supermin-split.sh supermin-make.sh \ libguestfs-supermin-helper \ kmod.whitelist \ - kmod.whitelist.in + kmod.whitelist.in \ + packagelist.in # Build the root filesystem (appliance). # Currently this is arch-dependent, so it seems like putting it in @@ -52,7 +53,7 @@ endif # This is for building the normal appliance: $(INITRAMFSIMG) $(VMLINUZ): $(top_builddir)/initramfs/fakeroot.log -$(top_builddir)/initramfs/fakeroot.log: make.sh kmod.whitelist +$(top_builddir)/initramfs/fakeroot.log: make.sh kmod.whitelist packagelist -mv $(INITRAMFSIMG) $(INITRAMFSIMG).bak -mv $(VMLINUZ) $(VMLINUZ).bak if ! bash make.sh; then rm -f $@; exit 1; fi @@ -65,6 +66,10 @@ $(INITRAMFSIMG): $(top_builddir)/initramfs/fakeroot.log $(top_builddir)/daemon/g kmod.whitelist: kmod.whitelist.in grep -v '^[[:space:]]*$$' < $< | grep -v '^#' > $@ +packagelist: packagelist.in + cpp -undef -DREDHAT=1 < $< | \ + grep -v '^[[:space:]]*$$' | grep -v '^#' > $@ + # This is for building the supermin appliance. It has to be enabled # specifically with './configure --enable-supermin'. You really need # to read the README file. diff --git a/appliance/make.sh.in b/appliance/make.sh.in index 15a2f65b..32b38194 100755 --- a/appliance/make.sh.in +++ b/appliance/make.sh.in @@ -24,28 +24,6 @@ set -e cd @top_builddir@ -modules=" --i augeas-libs --i bash --i binutils --i coreutils --i dosfstools --i file --i grub --i iputils --i kernel --i lvm2 --i MAKEDEV --i module-init-tools --i net-tools --i ntfs-3g --i ntfsprogs --i procps --i strace --i util-linux-ng --i zerofree -" - # Decide on names for the final output. These have to match Makefile.am. output=appliance/initramfs.@REPO@.@host_cpu@.img koutput=appliance/vmlinuz.@REPO@.@host_cpu@ @@ -53,7 +31,14 @@ rm -f $output rm -f $koutput # Create the basic initramfs. -@FEBOOTSTRAP@ $modules -u @UPDATES@ @REPO@ initramfs @MIRROR@ +exec 5<appliance/packagelist +packages= +while read pkg 0<&5; do + packages="$packages -i $pkg" +done +exec 5<&- + +@FEBOOTSTRAP@ $packages -u @UPDATES@ @REPO@ initramfs @MIRROR@ # /sysroot is where the guest root filesystem will be mounted. @FEBOOTSTRAP_RUN@ initramfs -- mkdir -p --mode=0777 /sysroot diff --git a/appliance/packagelist.in b/appliance/packagelist.in new file mode 100644 index 00000000..f335531f --- /dev/null +++ b/appliance/packagelist.in @@ -0,0 +1,28 @@ +/* This is the list of distro packages which are + * installed on the appliance. + * + * This file is processed by cpp with one of the + * following symbols defined (depending on the distro): + * + * REDHAT=1 For Fedora, RHEL, EPEL and workalikes. + */ + +augeas-libs +bash +binutils +coreutils +dosfstools +file +grub +iputils +kernel +lvm2 +MAKEDEV +module-init-tools +net-tools +ntfs-3g +ntfsprogs +procps +strace +util-linux-ng +zerofree |