vesper/Makefile.toml

54 lines
1.4 KiB
TOML

#
# SPDX-License-Identifier: BlueOak-1.0.0
#
# Copyright (c) Berkus Decker <berkus+vesper@metta.systems>
#
[config]
min_version = "0.32.0"
default_to_workspace = true
[env]
CARGO_MAKE_EXTEND_WORKSPACE_MAKEFILE = true
DEFAULT_TARGET = "aarch64-vesper-metta"
BUILD_STD = "-Zbuild-std=core,compiler_builtins,alloc"
DEVICE_FEATURES = "noserial"
QEMU_FEATURES = "qemu"
OBJCOPY = "rust-objcopy" # Part of `cargo objcopy` in cargo-binutils
OBJCOPY_PARAMS = "--strip-all -O binary"
UTILS_CONTAINER = "andrerichter/raspi3-utils"
DOCKER_CMD = "docker run -it --rm -v ${PWD}:/work -w /work -p 5900:5900"
QEMU_CONTAINER_CMD = "qemu-system-aarch64"
#
# Could additionally use -nographic to disable GUI -- this shall be useful for automated tests.
#
# -d in_asm,unimp,int
QEMU_OPTS = "-M raspi3 -d int -semihosting"
QEMU_SERIAL_OPTS = "-serial null -serial stdio"
QEMU_TESTS_OPTS = "-nographic"
QEMU = "qemu-system-aarch64"
# For gdb connection:
# - if setting this, MUST have gdb attached for SYS_WRITE0 to work, otherwise QEMU will crash.
QEMU_GDB_OPTS = "-gdb tcp::3333 -S"
TARGET_JSON = "${CARGO_MAKE_WORKSPACE_WORKING_DIRECTORY}/targets/${DEFAULT_TARGET}.json"
KERNEL_ELF = "${CARGO_MAKE_WORKSPACE_WORKING_DIRECTORY}/kernel8"
KERNEL_BIN = "${CARGO_MAKE_WORKSPACE_WORKING_DIRECTORY}/kernel8.img"
[tasks.default]
alias = "all"
[tasks.all]
dependencies = ["kernel-binary"]
[tasks.modules]
command = "cargo"
args = ["modules", "tree"]