File: Makefile

package info (click to toggle)
deft 0.8-5
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 180 kB
  • sloc: lisp: 1,035; makefile: 31; sh: 31
file content (33 lines) | stat: -rw-r--r-- 720 bytes parent folder | download | duplicates (3)
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
EMACS=emacs

PACKAGE=deft

SOURCE=deft.el
COMPILED=deft.elc

VERSION=$(shell cat $(SOURCE) | sed -n 's/^;;; Version: \(.*\)/\1/p')

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

all: $(COMPILED) README.md

.PHONY: dist

README.md: $(SOURCE) readme.sh
	./readme.sh

dist:
	DIR=$$(mktemp -d -t "$(PACKAGE)"); \
	DESTDIR="$$DIR/$(PACKAGE)-$(VERSION)"; \
	mkdir -p $$DESTDIR; \
	cp -a $(SOURCE) README.md $$DESTDIR; \
	tar zcf $(CURDIR)/$(PACKAGE)-$(VERSION).tar.gz -C $$DIR "$(PACKAGE)-$(VERSION)"; \
	rm -r $$DIR; \
	echo "$(PACKAGE)-$(VERSION).tar.gz has been created"

update: $(COMPILED)
	cp -a $(SOURCE) $(COMPILED) $(HOME)/.emacs.d/site-lisp

clean:
	rm -f $(COMPILED) index.text