mirror of
https://github.com/zephyrproject-rtos/zephyr
synced 2025-09-07 04:22:48 +00:00
This commit allows the `QEMU_KERNEL_OPTION` variable, which can be overridden by the `board.cmake`, to contain references to the variables that are not available at the time of `board.cmake` inclusion, by expanding its escpaed variable references in `cmake/emu/qemu.cmake` which is included nearby the end of the root `CMakeLists.txt`. With this change, the `board.cmake` can escape variable references as follows and allow them to be expanded later: set(QEMU_KERNEL_OPTION "-device;loader,file=\$<TARGET_FILE:$\{...}>") Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
23 lines
646 B
CMake
23 lines
646 B
CMake
# Copyright (c) 2019 Lexmark International, Inc.
|
|
#
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
set(EMU_PLATFORM qemu)
|
|
set(QEMU_ARCH xilinx-aarch64)
|
|
|
|
set(QEMU_CPU_TYPE_${ARCH} cortex-r5)
|
|
set(QEMU_FLAGS_${ARCH}
|
|
-nographic
|
|
-machine arm-generic-fdt
|
|
-icount shift=3,align=off,sleep=off -rtc clock=vm
|
|
-dtb ${ZEPHYR_BASE}/boards/${ARCH}/${BOARD}/fdt-single_arch-zcu102-arm.dtb
|
|
)
|
|
|
|
set(QEMU_KERNEL_OPTION
|
|
"-device;loader,file=\$<TARGET_FILE:\${logical_target_for_zephyr_elf}>,cpu-num=4"
|
|
"-device;loader,addr=0xff5e023c,data=0x80008fde,data-len=4"
|
|
"-device;loader,addr=0xff9a0000,data=0x80000218,data-len=4"
|
|
)
|
|
|
|
board_set_debugger_ifnset(qemu)
|