summaryrefslogtreecommitdiff
path: root/meta/classes/qemu.bbclass
diff options
context:
space:
mode:
authorLaurentiu Palcu <laurentiu.palcu@intel.com>2013-01-31 10:27:22 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-02-06 09:35:02 +0000
commit149a564bba7d3e1c2054ae6d908835ebd95b9084 (patch)
treeb191cdc7936e733ca70c74ceb574d561898b4a9e /meta/classes/qemu.bbclass
parentfaaa5e7fd4353b73289f163d9f601cf0869698f3 (diff)
downloadopenembedded-core-149a564bba7d3e1c2054ae6d908835ebd95b9084.tar.gz
openembedded-core-149a564bba7d3e1c2054ae6d908835ebd95b9084.tar.bz2
openembedded-core-149a564bba7d3e1c2054ae6d908835ebd95b9084.zip
qemu.bbclass: return qemuwrapper instead of qemu-allarch
When qemu bbclass is inherited from a recipe that is not architecture dependent, qemu_run_binary will return "qemu-allarch". However this binary does not exist. Instead, return "qemuwrapper" which will, in turn, execute the right binary for the target the image was built for. [YOCTO #2599] Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
Diffstat (limited to 'meta/classes/qemu.bbclass')
-rw-r--r--meta/classes/qemu.bbclass6
1 files changed, 5 insertions, 1 deletions
diff --git a/meta/classes/qemu.bbclass b/meta/classes/qemu.bbclass
index 13af3390aa..9cefabbf84 100644
--- a/meta/classes/qemu.bbclass
+++ b/meta/classes/qemu.bbclass
@@ -23,10 +23,14 @@ def qemu_target_binary(data):
# ${@qemu_run_binary(d, '$D', '/usr/bin/test_app')} [test_app arguments]
#
def qemu_run_binary(data, rootfs_path, binary):
+ qemu_binary = qemu_target_binary(data)
+ if qemu_binary == "qemu-allarch":
+ qemu_binary = "qemuwrapper"
+
dynamic_loader = rootfs_path + '$(readelf -l ' + rootfs_path + \
binary + '| grep "Requesting program interpreter"|sed -e \'s/^.*\[.*: \(.*\)\]/\\1/\')'
library_path = rootfs_path + data.getVar("base_libdir", True) + ":" + \
rootfs_path + data.getVar("libdir", True)
- return qemu_target_binary(data) + " " + dynamic_loader + " --library-path " + library_path \
+ return qemu_binary + " " + dynamic_loader + " --library-path " + library_path \
+ " " + rootfs_path + binary