summaryrefslogtreecommitdiff
path: root/Makefile
blob: c886a91489e0194536fc8591e1ea810ed2675f58 (plain)
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
CASK = cask
export EMACS ?= emacs
EMACSFLAGS =
TESTFLAGS =

PKGDIR := $(shell EMACS=$(EMACS) $(CASK) package-directory)

SRCS = $(wildcard *.el)
OBJS = $(SRCS:.el=.elc)

.PHONY: compile test clean

elpa:
	$(CASK) install
	$(CASK) update
	touch $@

compile: $(OBJS)

clean:
	rm -f $(OBJS)

test: $(PKGDIR)
	$(CASK) exec ert-runner $(TESTFLAGS)

test-checks:
	$(CASK) exec $(EMACS) --no-site-file --no-site-lisp --batch \
		-l test/test-checks.el ./

test-bytecomp: $(SRCS:.el=.elc-test)

%.elc-test: %.el elpa
	$(CASK) exec $(EMACS) --no-site-file --no-site-lisp --batch \
		-l test/clojure-mode-bytecomp-warnings.el $