Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up make system #270

Merged
merged 14 commits into from
Oct 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .commit-emoji.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
[[replacements]]
from = "deps"
to = "build(deps): 🛠 Update dependencies"

[[commit_types]]
name = "wip"
emoji = "🚧"
description = "Work in progress"
62 changes: 15 additions & 47 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

43 changes: 37 additions & 6 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,37 @@
[workspace]
members = [
"nucleus",
"machine",
"bin/chainboot",
"bin/chainofcommand"
]
members = ["machine", "nucleus", "bin/chainboot", "bin/chainofcommand"]
resolver = "2"

[workspace.package]
version = "0.0.1"
authors = ["Berkus Decker <[email protected]>"]
documentation = "https://docs.metta.systems/vesper"
homepage = "https://github.com/metta-systems/vesper"
repository = "https://github.com/metta-systems/vesper"
readme = "README.md"
license = "BlueOak-1.0.0"
categories = ["no-std", "embedded", "os"]
publish = false
edition = "2024"

[workspace.dependencies]
qemu-exit = "3.0"
aarch64-cpu = { version = "9.4.0", git = "https://github.com/rust-embedded/aarch64-cpu", branch = "main" }
tock-registers = "0.9"
ux = { version = "0.1", default-features = false }
usize_conversions = "0.2"
bit_field = "0.10"
bitflags = "2.6"
cfg-if = "1.0"
snafu = { version = "0.8", default-features = false, features = [
"unstable-core-error",
] }
buddy-alloc = { git = "https://github.com/metta-systems/buddy-alloc", version = "0.6.0", branch = "feature/allocator-api" }
once_cell = { version = "1.20", default-features = false, features = [
"unstable",
] }
seahash = "4.1"

[patch.crates-io]
serialport = { git = "https://github.com/metta-systems/serialport-rs", branch = "macos-ENOTTY-fix" }

Expand All @@ -21,6 +46,12 @@ panic = "abort"
opt-level = 's'
debug = true
lto = true
codegen-units = 1

[profile.release-fast]
inherits = "release"
lto = "thin"
codegen-units = 16

[profile.test]
opt-level = 's'
Expand Down
29 changes: 18 additions & 11 deletions Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ deps-up:

# Build default hw kernel and run chainofcommand to boot this kernel onto the board
boot: chainofcommand
cargo make chainboot
cargo make chainboot # make boot-kernel ?

# Build and run kernel in QEMU with serial port emulation
zellij:
Expand All @@ -24,7 +24,7 @@ zellij-cb:
# Build chainofcommand serial loader
chainofcommand:
cd bin/chainofcommand
cargo make build
cargo make build # --workspace=bin/chainofcommand

# Build and run kernel in QEMU
qemu:
Expand Down Expand Up @@ -59,8 +59,11 @@ cb-eject:

# Build default hw kernel
build:
cargo make build-device
cargo make kernel-binary
cargo make build

# Build default hw kernel (quietly)
qbuild:
cargo make build

alias b := build

Expand All @@ -86,7 +89,7 @@ alias disasm := hopper

# Build and disassemble kernel
hopper:
cargo make hopper
cargo make xtool-hopper

alias ocd := openocd

Expand All @@ -104,20 +107,24 @@ gdb-cb:

# Build and print all symbols in the kernel
nm:
cargo make nm

# Check formatting
fmt-check:
cargo fmt -- --check
cargo make xtool-nm

# Run `cargo expand` on nucleus
expand:
cargo make expand -- nucleus
cargo make xtool-expand-target -- nucleus

# Render modules dependency tree
modules:
cargo make xtool-modules

# Generate and open documentation
doc:
cargo make docs-flow

# Check formatting
fmt-check:
cargo fmt -- --check

# Run lint tasks
lint: clippy fmt-check

Expand Down
Loading