summaryrefslogtreecommitdiff
path: root/meta-xilinx/meta-xilinx-bsp/classes/qemuboot-xilinx.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'meta-xilinx/meta-xilinx-bsp/classes/qemuboot-xilinx.bbclass')
-rw-r--r--meta-xilinx/meta-xilinx-bsp/classes/qemuboot-xilinx.bbclass27
1 files changed, 27 insertions, 0 deletions
diff --git a/meta-xilinx/meta-xilinx-bsp/classes/qemuboot-xilinx.bbclass b/meta-xilinx/meta-xilinx-bsp/classes/qemuboot-xilinx.bbclass
new file mode 100644
index 0000000000..024626cbfa
--- /dev/null
+++ b/meta-xilinx/meta-xilinx-bsp/classes/qemuboot-xilinx.bbclass
@@ -0,0 +1,27 @@
+
+# enable the overrides for the context of the conf only
+OVERRIDES .= ":qemuboot-xilinx"
+
+# setup the target binary
+QB_SYSTEM_NAME_prepend = "qemu-xilinx/"
+
+# Default machine targets for Xilinx QEMU (FDT Generic)
+QB_MACHINE_aarch64 = "-machine arm-generic-fdt"
+QB_MACHINE_arm = "-machine arm-generic-fdt-7series"
+QB_MACHINE_microblaze = "-machine microblaze-generic-fdt-plnx"
+
+# defaults
+QB_DEFAULT_KERNEL ?= "none"
+
+inherit qemuboot
+
+# rewrite the qemuboot with the custom sysroot bindir
+python do_write_qemuboot_conf_append() {
+ val = os.path.join(d.getVar('BASE_WORKDIR'), d.getVar('BUILD_SYS'), 'qemu-xilinx-helper-native/1.0-r1/recipe-sysroot-native/usr/bin/')
+ cf.set('config_bsp', 'STAGING_BINDIR_NATIVE', '%s' % val)
+
+ # write out the updated version from this append
+ with open(qemuboot, 'w') as f:
+ cf.write(f)
+}
+