]> xenbits.xensource.com Git - people/gdunlap/raisin.git/.git/commitdiff
Move component specific functions to their own file.
authorStefano Stabellini <stefano.stabellini@eu.citrix.com>
Mon, 16 Mar 2015 10:39:19 +0000 (10:39 +0000)
committerStefano Stabellini <stefano.stabellini@eu.citrix.com>
Mon, 16 Mar 2015 10:39:19 +0000 (10:39 +0000)
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
grub.sh [new file with mode: 0644]
libvirt.sh [new file with mode: 0644]
xen.sh [new file with mode: 0644]

diff --git a/grub.sh b/grub.sh
new file mode 100644 (file)
index 0000000..7df8998
--- /dev/null
+++ b/grub.sh
@@ -0,0 +1,27 @@
+#!/usr/bin/env bash
+
+source config
+
+clean_grub() {
+    rm -rf memdisk.tar
+    rm -rf grub-dir
+}
+
+build_grub() {
+    tar cf memdisk.tar grub.cfg
+    ./git-checkout.sh $GRUB_UPSTREAM_URL $GRUB_UPSTREAM_REVISION grub-dir
+    cd grub-dir
+    ./autogen.sh
+    ## GRUB32
+    ./configure --target=i386 --with-platform=xen
+    $MAKE
+    ./grub-mkimage -d grub-core -O i386-xen -c ../grub-bootstrap.cfg -m ../memdisk.tar -o grub-i386-xen grub-core/*mod
+    cp grub-i386-xen "$INST_DIR"/$PREFIX/lib/xen/boot
+    ## GRUB64
+    $MAKE clean
+    ./configure --target=amd64 --with-platform=xen
+    $MAKE
+    ./grub-mkimage -d grub-core -O x86_64-xen -c ../grub-bootstrap.cfg -m ../memdisk.tar -o grub-x86_64-xen grub-core/*mod
+    cp grub-x86_64-xen "$INST_DIR"/$PREFIX/lib/xen/boot
+    cd ..
+}
diff --git a/libvirt.sh b/libvirt.sh
new file mode 100644 (file)
index 0000000..12e2533
--- /dev/null
@@ -0,0 +1,23 @@
+#!/usr/bin/env bash
+
+source config
+
+clean_libvirt() {
+    rm -rf libvirt-dir
+}
+
+build_libvirt() {
+    ./git-checkout.sh $LIBVIRT_UPSTREAM_URL $LIBVIRT_UPSTREAM_REVISION libvirt-dir
+    cd libvirt-dir
+    ./autogen.sh --disable-threads --with-xen --without-qemu --without-uml     \
+       --without-outopenvz --without-vmware --without-libssh2 --without-phyp  \
+       --without-xenapi --with-libxl --without-vbox --without-lxc             \
+       --without-esx --without-hyperv --without-parallels --without-test      \
+       --without-remote --with-libvirtd --without-sasl --with-yajl            \
+       --without-dbus --without-selinux --without-python --without-apparmor   \
+       --without-macvtap --without-avahi --without-openvz --without-dbus      \
+       --prefix=$PREFIX
+    $MAKE
+    $MAKE --ignore-errors install DESTDIR=$INST_DIR
+    cd ..
+}
diff --git a/xen.sh b/xen.sh
new file mode 100644 (file)
index 0000000..c74ec58
--- /dev/null
+++ b/xen.sh
@@ -0,0 +1,16 @@
+#!/usr/bin/env bash
+
+source config
+
+clean_xen() {
+    rm -rf xen-dir
+}
+
+build_xen() {
+    ./git-checkout.sh $XEN_UPSTREAM_URL $XEN_UPSTREAM_REVISION xen-dir
+    cd xen-dir
+    ./configure --prefix=$PREFIX
+    $MAKE
+    $MAKE install DESTDIR="$INST_DIR"
+    cd ..
+}