Files
Hakysidian/makefile

28 lines
642 B
Makefile
Raw Normal View History

2026-03-20 13:04:46 +08:00
COMMANDS := build watch rebuild clean
BIN := hakysidian
2026-03-20 13:04:46 +08:00
.PHONY: $(COMMANDS), publish
# Set the default goal, so running 'make' without arguments will run 'make build'.
.DEFAULT_GOAL := build
# ---
$(COMMANDS): $(BIN)
@echo "Running command: ./$(BIN) $@"
-@./$(BIN) $@
2026-03-20 13:04:46 +08:00
# --- Rules ---
# using relative symlinks should be fine since everything only works at ./
$(BIN): src/site.hs src/ChaoDoc.hs
cabal build exe:hakysidian
ln -sf "$(shell cabal list-bin exe:hakysidian)" $(BIN)
2026-03-20 13:04:46 +08:00
# move from katex to mathjax
# katex_cli:
# cd katex_rust_fork && cargo build --release
# ln -sf ./katex_rust_fork/target/release/katex_cli katex_cli