mirror of
git://git.yoctoproject.org/meta-virtualization.git
synced 2025-07-19 12:50:22 +02:00
xvisor: Add support for building AArch64
Add support for building for AArch64, also remove the requirement to specify a platform. Signed-off-by: Alistair Francis <alistair.francis@wdc.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
This commit is contained in:
parent
8ffc613d12
commit
3d27b83998
|
@ -1,15 +1,15 @@
|
|||
def get_oemake_config(d):
|
||||
plat = d.getVar('XVISOR_PLAT')
|
||||
def get_oemake_config(a, d):
|
||||
import re
|
||||
|
||||
if plat is None:
|
||||
return ""
|
||||
|
||||
if 'riscv/virt32' in plat:
|
||||
return "generic-32b-defconfig"
|
||||
if 'riscv/virt64' in plat:
|
||||
return "generic-64b-defconfig"
|
||||
|
||||
return ""
|
||||
if re.match('armeb$', a): return 'generic-v7-defconfig'
|
||||
elif re.match('aarch64$', a): return 'generic-v8-defconfig'
|
||||
elif re.match('aarch64_be$', a): return 'generic-v8-defconfig'
|
||||
elif re.match('aarch64_ilp32$', a): return 'generic-v8-defconfig'
|
||||
elif re.match('aarch64_be_ilp32$', a): return 'generic-v8-defconfig'
|
||||
elif re.match('riscv32(eb|)$', a): return 'generic-32b-defconfig'
|
||||
elif re.match('riscv64(eb|)$', a): return 'generic-64b-defconfig'
|
||||
else:
|
||||
bb.error("cannot map '%s' to a Xvisor defconfig" % a)
|
||||
|
||||
def map_xvisor_arch(a, d):
|
||||
import re
|
||||
|
|
|
@ -18,7 +18,7 @@ S = "${WORKDIR}/git"
|
|||
|
||||
EXTRA_OEMAKE += "ARCH=\"${@map_xvisor_arch(d.getVar('TARGET_ARCH'), d)}\" I=${D}"
|
||||
|
||||
CONFIG = "${@get_oemake_config(d)}"
|
||||
CONFIG = "${@get_oemake_config(d.getVar('TARGET_ARCH'), d)}"
|
||||
|
||||
do_configure() {
|
||||
oe_runmake ${CONFIG}
|
||||
|
@ -35,11 +35,16 @@ do_install_append() {
|
|||
do_deploy () {
|
||||
install -d ${DEPLOY_DIR_IMAGE}
|
||||
install -m 755 ${D}/vmm.* ${DEPLOY_DIR_IMAGE}/
|
||||
|
||||
if [[ -f "${D}/*.dtb" ]]; then
|
||||
install -m 755 ${D}/*.dtb ${DEPLOY_DIR_IMAGE}/
|
||||
fi
|
||||
}
|
||||
|
||||
addtask deploy after do_install
|
||||
|
||||
FILES_${PN} += "/vmm.*"
|
||||
FILES_${PN} += "/*.dtb"
|
||||
|
||||
COMPATIBLE_HOST = "(riscv64|riscv32).*"
|
||||
COMPATIBLE_HOST = "(aarch64|riscv64|riscv32).*"
|
||||
INHIBIT_PACKAGE_STRIP = "1"
|
||||
|
|
Loading…
Reference in New Issue
Block a user