summaryrefslogtreecommitdiffstats
path: root/meta/classes/qemu.bbclass
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2014-12-04 19:49:19 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-12-05 18:01:08 +0000
commitb813bdebb36501500e86fea5f7e15b4b15ea0902 (patch)
tree6effca63bb30254ee4ee76a8dc263d5e6c17c7e2 /meta/classes/qemu.bbclass
parentda53141db3bb446db7b036b95df2f860c6cbe276 (diff)
downloadpoky-474031ad5619f25589ef4e08987abe8c7192d16a.tar.gz
qemu/libc-package: Fix qemu option handling1.8_M1
The 'overrides' here are PACKAGE_ARCH based and hence not overrides as such and the _append wasn't working in many cases. This adjusts the code to use PACKAGE_ARCH as the accessor and ensures the variables work as expected. This fixes various segfaults and ensures postinsts run at build time rather than on the target system. The bug was introduced in http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=7efad8a1b56df6ee07c12ad360c0493d7b1d6d23. (From OE-Core rev: 219e793907406eabf632e784e3a11ab9acb77cfb) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/qemu.bbclass')
-rw-r--r--meta/classes/qemu.bbclass29
1 files changed, 16 insertions, 13 deletions
diff --git a/meta/classes/qemu.bbclass b/meta/classes/qemu.bbclass
index b2cf85d628..601f587534 100644
--- a/meta/classes/qemu.bbclass
+++ b/meta/classes/qemu.bbclass
@@ -29,20 +29,23 @@ def qemu_run_binary(data, rootfs_path, binary):
29 29
30 libdir = rootfs_path + data.getVar("libdir", False) 30 libdir = rootfs_path + data.getVar("libdir", False)
31 base_libdir = rootfs_path + data.getVar("base_libdir", False) 31 base_libdir = rootfs_path + data.getVar("base_libdir", False)
32 oldest_kernel = data.getVar("OLDEST_KERNEL", True) 32 qemu_options = data.getVar("QEMU_OPTIONS", True)
33 33
34 return "PSEUDO_UNLOAD=1 " + qemu_binary + " -r " + oldest_kernel + " -L " + rootfs_path\ 34 return "PSEUDO_UNLOAD=1 " + qemu_binary + " " + qemu_options + " -L " + rootfs_path\
35 + " -E LD_LIBRARY_PATH=" + libdir + ":" + base_libdir + " "\ 35 + " -E LD_LIBRARY_PATH=" + libdir + ":" + base_libdir + " "\
36 + rootfs_path + binary 36 + rootfs_path + binary
37 37
38QEMU_OPTIONS = "-r ${OLDEST_KERNEL}" 38# QEMU_EXTRAOPTIONS is not meant to be directly used, the extensions are
39QEMU_OPTIONS_append_iwmmxt = " -cpu pxa270-c5" 39# PACKAGE_ARCH, not overrides and hence have to do this dance. Simply being arch
40QEMU_OPTIONS_append_armv6 = " -cpu arm1136" 40# specific isn't good enough.
41QEMU_OPTIONS_append_armv7a = " -cpu cortex-a8" 41QEMU_OPTIONS = "-r ${OLDEST_KERNEL} ${@d.getVar("QEMU_EXTRAOPTIONS_%s" % d.getVar('PACKAGE_ARCH', True), True) or ""}"
42QEMU_OPTIONS_append_e500v2 = " -cpu e500v2" 42QEMU_EXTRAOPTIONS_iwmmxt = " -cpu pxa270-c5"
43QEMU_OPTIONS_append_e500mc = " -cpu e500mc" 43QEMU_EXTRAOPTIONS_armv6 = " -cpu arm1136"
44QEMU_OPTIONS_append_e5500 = " -cpu e5500" 44QEMU_EXTRAOPTIONS_armv7a = " -cpu cortex-a8"
45QEMU_OPTIONS_append_e5500-64b = " -cpu e5500" 45QEMU_EXTRAOPTIONS_e500v2 = " -cpu e500v2"
46QEMU_OPTIONS_append_e6500 = " -cpu e6500" 46QEMU_EXTRAOPTIONS_e500mc = " -cpu e500mc"
47QEMU_OPTIONS_append_e6500-64b = " -cpu e6500" 47QEMU_EXTRAOPTIONS_e5500 = " -cpu e5500"
48QEMU_OPTIONS_append_ppc7400 = " -cpu 7400" 48QEMU_EXTRAOPTIONS_e5500-64b = " -cpu e5500"
49QEMU_EXTRAOPTIONS_e6500 = " -cpu e6500"
50QEMU_EXTRAOPTIONS_e6500-64b = " -cpu e6500"
51QEMU_EXTRAOPTIONS_ppc7400 = " -cpu 7400"