Files
meta-riscv/conf/machine/riscv32.conf
Taras Kondratiuk 39a3237db5 machine: remove MACHINE_ARCH override to fix package collision
Machine-specific packages (like Linux kernel) should have
machine-specific PACKAGE_ARCH that is obtained from MACHINE_ARCH. This
allows to separate their build artifacts in TMPDIR.

Currently all RISC-V machines override MACHINE_ARCH and artifacts for
machine-specific recipes collide. For example kernels of both
qemuriscv64 and freedom-u540 machines will be deployed into the same
$D directory.

Remove MACHINE_ARCH override and set tune PACKAGE_ARCH via
PACKAGE_EXTRA_ARCHS.

Signed-off-by: Taras Kondratiuk <takondra@cisco.com>
2018-04-29 07:19:32 -07:00

32 lines
1.0 KiB
Plaintext

#@TYPE: Machine
#@NAME: generic riscv32 baremetal machine
#@DESCRIPTION: Machine configuration for running a generic riscv32
DEFAULTTUNE = "riscv32"
require conf/machine/include/qemu.inc
require conf/machine/include/tune-riscv.inc
PREFERRED_VERSION_qemu = "${QEMUVERSION}"
PREFERRED_VERSION_qemu-native = "${QEMUVERSION}"
PREFERRED_VERSION_nativesdk-qemu = "${QEMUVERSION}"
GDBVERSION = "riscv"
QEMUVERSION = "riscv"
# qemuboot options
QB_MACHINE = "-machine virt"
QB_DEFAULT_KERNEL = "bbl"
QB_NETWORK_DEVICE = "-device virtio-net-device,netdev=net0,mac=@MAC@"
QB_ROOTFS_OPT = "-drive file=@ROOTFS@,format=raw,id=hd0 -device virtio-blk-device,drive=hd0"
QB_SLIRP_OPT = "-netdev user,id=net0,hostfwd=tcp::22222-:22"
# Prelink does not yet work
USER_CLASSES_remove = "image-prelink"
# To support baremetal ld complains
# /opt/riscv32/sysroots/x86_64-becsdk-linux/usr/libexec/riscv32-bec-elf/gcc/riscv32-bec-elf/7.3.0/real-ld: unrecognized option '--hash-style=gnu'
#TARGET_LINK_HASH_STYLE = ""
LINKER_HASH_STYLE = ""
TCLIBC = "baremetal"