diff options
Diffstat (limited to 'meta/classes/qemu.bbclass')
| -rw-r--r-- | meta/classes/qemu.bbclass | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/meta/classes/qemu.bbclass b/meta/classes/qemu.bbclass new file mode 100644 index 0000000000..66dfb2b0d2 --- /dev/null +++ b/meta/classes/qemu.bbclass | |||
| @@ -0,0 +1,15 @@ | |||
| 1 | # | ||
| 2 | # This class contains functions for recipes that need QEMU or test for its | ||
| 3 | # existance. | ||
| 4 | # | ||
| 5 | |||
| 6 | def qemu_target_binary(data): | ||
| 7 | import bb | ||
| 8 | |||
| 9 | target_arch = bb.data.getVar("TARGET_ARCH", data, 1) | ||
| 10 | if target_arch in ("i486", "i586", "i686"): | ||
| 11 | target_arch = "i386" | ||
| 12 | elif target_arch == "powerpc": | ||
| 13 | target_arch = "ppc" | ||
| 14 | |||
| 15 | return "qemu-" + target_arch | ||
