name the submission zip after the member and pack their tests and testbenches

Co-Authored-By: wade-ai <[email protected]>
This commit is contained in:
Wade Tran
2026-09-17 11:57:27 -04:00
co-authored by wade-ai
parent 0eace93dfd
commit b558beb69f
2 changed files with 23 additions and 11 deletions
+1 -1
View File
@@ -11,5 +11,5 @@ __pycache__/
sim/behav/WORKSPACE/
# Submission packaging
submission_*.zip
*-dd-fall26.zip
regress.log
+22 -10
View File
@@ -1,11 +1,17 @@
# Fill these in before running make submit, for example:
# MEMBER_NAME = George Burdell
# GT_USERNAME = gburdell3
# DISCORD_NAME = gburdell67discord
MEMBER_NAME =
GT_USERNAME =
DISCORD_NAME =
PYTHON ?= python3
TEST ?= ebreak
TEST_DIR := tests/$(TEST)
MAX_CPU_CYCLES ?= 1000
CROSSBAR_TIMEOUT ?= 20
SUBMISSION := submission_$(USER).zip
TEST_NAMES := $(sort $(notdir $(patsubst %/,%,$(dir $(wildcard tests/*/program.asm)))))
.PHONY: help generate smoke test regress submit clean clean-generated
@@ -15,7 +21,7 @@ help:
@echo "make smoke Test build/TB wiring with a mock DUT"
@echo "make test TEST=<name> Generate and run one RTL test"
@echo "make regress Run every test, print PASS/FAIL summary (logs in tests/<name>/sim.log)"
@echo "make submit Run regress and zip src/ with the log into $(SUBMISSION)"
@echo "make submit Run regress and zip your sources, tests and log for checkoff"
@echo "make clean Remove generated test and simulator files"
@echo "Available tests: $(TEST_NAMES)"
@@ -58,13 +64,19 @@ regress:
fi
submit:
@rm -f $(SUBMISSION) regress.log .regress_status
@{ $(MAKE) --no-print-directory regress; echo $$? > .regress_status; } 2>&1 | tee regress.log
@zip -qr $(SUBMISSION) src regress.log -x '*.DS_Store'
@echo "----------------------------------------"
@if [ "$$(cat .regress_status)" != "0" ]; then echo "WARNING: not all tests pass, see regress.log"; fi
@rm -f .regress_status
@echo "Wrote $(SUBMISSION) for $(USER)"
@if [ -z "$(strip $(MEMBER_NAME))" ] || [ -z "$(strip $(GT_USERNAME))" ] || [ -z "$(strip $(DISCORD_NAME))" ]; then \
echo "Fill in MEMBER_NAME, GT_USERNAME and DISCORD_NAME at the top of the Makefile first."; \
exit 2; \
fi
@submission="$$(echo '$(strip $(MEMBER_NAME))' | tr -d ' ')-$(strip $(GT_USERNAME))-$(strip $(DISCORD_NAME))-dd-fall26.zip"; \
rm -f "$$submission" regress.log .regress_status; \
{ $(MAKE) --no-print-directory regress; echo $$? > .regress_status; } 2>&1 | tee regress.log; \
zip -qr "$$submission" src sim/behav/Include tests regress.log \
-x '*.DS_Store' 'tests/*/program.o' 'tests/*/program.hex' 'tests/*/sim.log'; \
echo "----------------------------------------"; \
if [ "$$(cat .regress_status)" != "0" ]; then echo "WARNING: not all tests pass, see regress.log"; fi; \
rm -f .regress_status; \
echo "Wrote $$submission"
clean:
$(MAKE) -C sim/behav clean