Something went wrong. Try again.
Hardware-in-the-loop development platform for the Commodore 64.
Something went wrong. Try again.
ultimate-tool Makefile
3.5 kB · 73 lines
Makefile
at main
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374.PHONY: check check-python check-browser check-all demo validate fixture fixture-timeline fixture-riscv test-fake test-vice serve release-env dist check-release check-release-publication
# Local development packaging only. Publication uses a separate reviewed,# annotated-tag preflight and never runs from a Make target.RELEASE_ENV_IMAGE ?= ultimate-tool-release-envDIST_DIR ?= distDEVELOPMENT_LABEL ?= local-development# Supply both paths to attach independently checked linked-runtime sources.RUNTIME_SOURCES_REPORT ?=RUNTIME_SOURCES_DIR ?=RUNTIME_SOURCE_ARGS = $(if $(RUNTIME_SOURCES_REPORT),--runtime-sources-report "$(RUNTIME_SOURCES_REPORT)") $(if $(RUNTIME_SOURCES_DIR),--runtime-sources-dir "$(RUNTIME_SOURCES_DIR)")
check: cargo fmt --all -- --check cargo clippy --locked --workspace --all-targets -- -D warnings cargo test --locked --workspace node --test 'crates/ultimate-tool-server/web/test/*.test.cjs' git diff --check
check-browser: cargo build --locked -p ultimate-tool npm run test:browser
check-python: python3 -m unittest discover -s tests/python -v python3 tools/check_distribution_docs.py
check-all: check check-python check-browser
demo: cargo build --locked -p ultimate-tool python3 tools/run_demo.py
validate: cargo run -q -p ultimate-tool -- validate
fixture: $(MAKE) -C fixtures/rust-mos-smoke build
fixture-timeline: $(MAKE) -C fixtures/rust-mos-timeline verify-reproducible
fixture-riscv: $(MAKE) -C fixtures/riscv-ue2-smoke verify
test-fake: cargo run -q -p ultimate-tool -- test smoke --target fake
test-vice: cargo run -q -p ultimate-tool -- test smoke --target vice
serve: cargo run -q -p ultimate-tool -- serve
# Explicit setup: downloads occur here, not in ordinary check targets.release-env: docker build -f tools/release-env/Dockerfile -t "$(RELEASE_ENV_IMAGE)" --build-arg BUILD_UID="$$(id -u)" --build-arg BUILD_GID="$$(id -g)" .
# Freeze corresponding source first, then build only its fresh extraction.# DIST_DIR and DIST_BUILD_DIR must be new; conflicting files are never replaced.DIST_BUILD_DIR ?= /tmp/ultimate-tool-dist-build-$(notdir $(DIST_DIR))dist: docker run --rm --user "$$(id -u):$$(id -g)" -v "$(CURDIR):/work" -w /work "$(RELEASE_ENV_IMAGE)" python3 tools/package_release.py --prepare-source --output "$(DIST_DIR)" --development "$(DEVELOPMENT_LABEL)" $(RUNTIME_SOURCE_ARGS) python3 tools/build_release_source.py --source-dir "$(DIST_DIR)" --work-dir "$(DIST_BUILD_DIR)" --image "$(RELEASE_ENV_IMAGE)" python3 -c 'import json, subprocess, sys; from pathlib import Path; r=json.loads((Path(sys.argv[1])/"build-result.json").read_text()); subprocess.run([sys.executable, "tools/package_release.py", "--pack", "--binary-dir", r["binary_dir"], "--build-env", r["build_env"], "--output", sys.argv[2], "--development", sys.argv[3]], check=True)' "$(DIST_BUILD_DIR)" "$(DIST_DIR)" "$(DEVELOPMENT_LABEL)"
# Development verification reports pending release policies explicitly.check-release: python3 tools/check_release.py --release-dir "$(DIST_DIR)" --mode development python3 -c 'import json, subprocess, sys; from pathlib import Path; d=Path(sys.argv[1]); r=json.loads((d/"release-manifest.json").read_text()); subprocess.run([sys.executable, "tools/check_distribution_docs.py", "--source-archive", str(d/r["source_archive"]["name"]), "--binary-archive", str(d/r["archive"]["name"])], check=True)' "$(DIST_DIR)"
check-release-publication: python3 tools/check_release.py --release-dir "$(DIST_DIR)" --mode release