f83c8f25e4
Installs bat Forth syntax, then cargo install --locked the CLI. CARGO_PROFILE_RELEASE_STRIP=none because Cargo's release default (strip = "debuginfo") emits dylibs macOS 27 dyld rejects with "mis-aligned LINKEDIT string pool"; proc macros then fail to load during the build.
81 lines
2.0 KiB
Makefile
81 lines
2.0 KiB
Makefile
default:
|
|
just --list
|
|
|
|
# Build everything
|
|
build:
|
|
cargo build --workspace
|
|
|
|
# Run all tests
|
|
test:
|
|
cargo test --workspace
|
|
|
|
# Run Forth 2012 compliance tests
|
|
compliance:
|
|
cargo test --test compliance -- --nocapture
|
|
|
|
# Run clippy lints
|
|
clippy:
|
|
cargo clippy --workspace -- -D warnings
|
|
|
|
# Check formatting (Rust + Markdown)
|
|
fmt:
|
|
cargo fmt --all --check
|
|
dprint check
|
|
|
|
# Format code (Rust + Markdown)
|
|
fmt-fix:
|
|
cargo fmt --all
|
|
dprint fmt
|
|
|
|
# Run the REPL
|
|
repl:
|
|
cargo run -p wafer
|
|
|
|
# Run a Forth file
|
|
run file:
|
|
cargo run -p wafer -- {{file}}
|
|
|
|
# Run benchmarks
|
|
bench:
|
|
cargo bench --workspace
|
|
|
|
# Run optimization benchmark report
|
|
bench-opts:
|
|
cargo test -p wafer-core --test benchmark_report -- --nocapture --ignored
|
|
|
|
# Cross-engine performance report: WAFER vs gforth vs SwiftForth (sf64)
|
|
bench-compare:
|
|
CARGO_PROFILE_RELEASE_STRIP=none cargo test -p wafer-core --release --test comparison -- --nocapture --ignored performance_report
|
|
|
|
# Cross-engine correctness lanes: program corpus vs gforth + sf64 oracles
|
|
compare-correctness:
|
|
cargo test -p wafer-core --test comparison -- --nocapture --ignored compare_all_programs
|
|
|
|
# Check dependency licenses and advisories
|
|
deny:
|
|
cargo deny check
|
|
|
|
# Detect unused dependencies
|
|
machete:
|
|
cargo machete --skip-target-dir
|
|
|
|
# Full CI check (what CI runs)
|
|
ci: fmt clippy deny test
|
|
|
|
# Check compilation without running
|
|
check:
|
|
cargo check --workspace
|
|
|
|
# Install the wafer CLI (release build) and bat syntax highlighting.
|
|
# STRIP=none: Cargo's release default (strip = "debuginfo") emits dylibs that
|
|
# macOS 27's dyld rejects ("mis-aligned LINKEDIT string pool"), so proc macros
|
|
# fail to load during the build itself.
|
|
install: install-syntax
|
|
CARGO_PROFILE_RELEASE_STRIP=none cargo install --path crates/cli --locked
|
|
|
|
# Install bat syntax highlighting for WAFER / Forth
|
|
install-syntax:
|
|
mkdir -p ~/.config/bat/syntaxes
|
|
cp tools/editor-support/bat/WAFER.sublime-syntax ~/.config/bat/syntaxes/
|
|
bat cache --build
|