summaryrefslogtreecommitdiff
path: root/Makefile
blob: a1eaa78aca1ed8251dbc8256c569add5640c9b45 (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
DIRS	= $(shell find . ! -name CVS -type d)
SPECIAL = chess-auto.el
SOURCE	= $(filter-out $(SPECIAL),$(shell find -name '*.el'))
TARGET	= $(patsubst %.el,%.elc,$(SPECIAL) $(SOURCE))
EMACS   = emacs

all: $(TARGET)
	-rm subdirs.elc

chess-auto.el: chess-auto.in $(SOURCE)
	cp chess-auto.in chess-auto.el
	-rm chess-auto.elc
	$(EMACS) --no-init-file --no-site-file -batch \
		-l $(shell pwd)/chess-auto \
		-f generate-autoloads \
		$(shell pwd)/chess-auto.el $(DIRS)

%.elc: %.el
	$(EMACS) --no-init-file --no-site-file -batch \
		-f batch-byte-compile $<

clean:
	rm -f $(TARGET) *~

fullclean: clean
	-rm *.elc chess-auto.el