xen: separate the extra steps into their own tasks

do_configure() was overloaded with a lot of behaviors that really were
source code patching so instead make them as extra tasks that happen
after do_patch() and before do_configure().

Signed-off-by: Doug Goldstein <cardoe@cardoe.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
This commit is contained in:
Doug Goldstein 2016-01-26 13:09:20 -06:00 committed by Bruce Ashfield
parent 12a7d544f4
commit a19e5567dc
2 changed files with 20 additions and 13 deletions

View File

@ -731,7 +731,21 @@ python () {
d.setVar('XSM_ENABLED', '0') d.setVar('XSM_ENABLED', '0')
} }
do_configure() { do_post_patch() {
# fixup AS/CC/CCP/etc variable within StdGNU.mk
for i in LD CC CPP CXX; do
sed -i "s/^\($i\s\s*\).*=/\1?=/" ${S}/config/StdGNU.mk
done
# fixup environment passing in some makefiles
sed -i 's#\(\w*\)=\(\$.\w*.\)#\1="\2"#' ${S}/tools/firmware/Makefile
# libsystemd-daemon -> libsystemd for newer systemd versions
sed -i 's#libsystemd-daemon#libsystemd#' ${S}/tools/configure
}
addtask post_patch after do_patch before do_configure
do_stubs() {
# no stubs-32.h in our 64-bit sysroot - hack it into tools/include/gnu # no stubs-32.h in our 64-bit sysroot - hack it into tools/include/gnu
if ! test -f ${STAGING_DIR_TARGET}/usr/include/gnu/stubs-32.h ; then if ! test -f ${STAGING_DIR_TARGET}/usr/include/gnu/stubs-32.h ; then
if test -f ${STAGING_DIR_TARGET}/usr/include/gnu/stubs-64.h ; then if test -f ${STAGING_DIR_TARGET}/usr/include/gnu/stubs-64.h ; then
@ -742,6 +756,11 @@ do_configure() {
echo \#define __stub___kernel_tanl >> ${S}/tools/include/gnu/stubs-32.h echo \#define __stub___kernel_tanl >> ${S}/tools/include/gnu/stubs-32.h
fi fi
fi fi
}
addtask stubs after do_patch before do_configure
do_configure() {
#./configure --enable-xsmpolicy does not set XSM_ENABLE must be done manually #./configure --enable-xsmpolicy does not set XSM_ENABLE must be done manually
if [ "${XSM_ENABLED}" = "1" ]; then if [ "${XSM_ENABLED}" = "1" ]; then

View File

@ -27,18 +27,6 @@ EXTRA_OEMAKE += "SEABIOS_ROM=${STAGING_DIR_HOST}/usr/share/firmware/bios.bin"
EXTRA_OEMAKE += "ETHERBOOT_ROMS=${STAGING_DIR_HOST}/usr/share/firmware/rtl8139.rom" EXTRA_OEMAKE += "ETHERBOOT_ROMS=${STAGING_DIR_HOST}/usr/share/firmware/rtl8139.rom"
#EXTRA_OEMAKE += "XENGFX_ROM=${STAGING_DIR_HOST}/usr/share/firmware/vgabios.bin" #EXTRA_OEMAKE += "XENGFX_ROM=${STAGING_DIR_HOST}/usr/share/firmware/vgabios.bin"
do_configure_prepend() {
# fixup AS/CC/CCP/etc variable within StdGNU.mk
for i in LD CC CPP CXX; do
sed -i "s/^\($i\s\s*\).*=/\1?=/" ${S}/config/StdGNU.mk
done
# fixup environment passing in some makefiles
sed -i 's#\(\w*\)=\(\$.\w*.\)#\1="\2"#' ${S}/tools/firmware/Makefile
# libsystemd-daemon -> libsystemd for newer systemd versions
sed -i 's#libsystemd-daemon#libsystemd#' ${S}/tools/configure
}
do_install_append() { do_install_append() {
# fixup default path to qemu-system-i386 # fixup default path to qemu-system-i386
sed -i 's#\(test -z "$QEMU_XEN" && QEMU_XEN=\).*$#\1"/usr/bin/qemu-system-i386"#' ${D}/etc/init.d/xencommons sed -i 's#\(test -z "$QEMU_XEN" && QEMU_XEN=\).*$#\1"/usr/bin/qemu-system-i386"#' ${D}/etc/init.d/xencommons