Skip to content

build(Makefile): add clean target and refactor the overall structure#19

Merged
hyperfinitism merged 1 commit intomainfrom
build/refactor-makefile
Mar 6, 2026
Merged

build(Makefile): add clean target and refactor the overall structure#19
hyperfinitism merged 1 commit intomainfrom
build/refactor-makefile

Conversation

@hyperfinitism
Copy link
Collaborator

Changes

  • Introduce file-target rules for build artifacts (rafwne-enclave.eif, target/release/rafwne-proxy, target/release/rafwne-client) so Make can skip unnecessary rebuilds via timestamp checks; PHONY aliases (build-enclave, build-proxy, build-client) delegate to these file targets
  • Add prerequisites to run-* targets (run-enclaverafwne-enclave.eif, run-proxytarget/release/rafwne-proxy, run-clienttarget/release/rafwne-client + root.pem) so that builds are triggered automatically when needed
  • Replace cargo run with direct binary invocation (./target/release/...) in run-proxy and run-client to avoid redundant Cargo dependency resolution at runtime
  • Add clean target (cargo clean, Docker image removal, rafwne-enclave.eif / root.pem cleanup)
  • Add .DELETE_ON_ERROR to prevent partial/stale artifacts from surviving failed recipes
  • Set .DEFAULT_GOAL := help explicitly
  • Refactor help target to auto-generate descriptions from inline ## ... comments on each target
  • Move from a single top-level .PHONY declaration to per-target .PHONY for maintainability
  • Remove blanket @ silencing from recipe commands to aid debugging; retain @ only on cosmetic echo / printf lines
  • Refactor terminate-enclave to use jq --argjson instead of interpolating Make variables inside a jq filter string
  • Organize targets into commented sections (Help / Clean / Setup / Build / Run / Terminate) for readability

Notes

No functional changes to build outputs or runtime behavior.

@hyperfinitism hyperfinitism self-assigned this Mar 6, 2026
@hyperfinitism hyperfinitism merged commit f1732f9 into main Mar 6, 2026
22 checks passed
@hyperfinitism hyperfinitism deleted the build/refactor-makefile branch March 6, 2026 10:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant