-
Notifications
You must be signed in to change notification settings - Fork 21
/
Makefile
37 lines (26 loc) · 1 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
.POSIX:
EMACS ?= cask exec emacs
SRC = weblorg.el
TESTSRC = t/weblorg-tests.el
OBJ = weblorg.elc
TESTOBJ = t/weblorg-tests.elc
ALLOBJS = $(OBJ) $(TESTOBJ)
# NOTE: This is meant to accelerate local development. Although
# templatel is being installed via Cask, this generic path is still
# being injected into `load-path' so if there's a copy of templatel
# there, it will be prioritized over the one installed by Cask.
TEMPLATEL = --eval "(add-to-list 'load-path \"~/src/github.com/clarete/templatel/\")"
CASK_MARK = .cask/done
all: $(ALLOBJS)
$(OBJ): $(SRC)
$(TESTOBJ): $(OBJ) $(TESTSRC)
clean:; rm -f $(ALLOBJS)
$(CASK_MARK):; cask install && touch .cask/done
deps: $(CASK_MARK)
check: deps $(TESTOBJ)
$(EMACS) -batch -Q -L . $(TEMPLATEL) -l $(TESTOBJ) -f ert-run-tests-batch-and-exit
check-one: $(TESTOBJ)
$(EMACS) -batch -Q -L . $(TEMPLATEL) -l $(TESTOBJ) --eval "(ert-run-tests-batch-and-exit '(member ${TEST}))"
.SUFFIXES: .el .elc
.el.elc:
$(EMACS) -batch -Q -L . $(TEMPLATEL) -f batch-byte-compile $<