Pressing Enter in the diff view will now scroll it one line down
[tig] / Makefile
CommitLineData
4c6fabc2 1PREFIX = $(HOME)
c9a2f784 2LDLIBS = -lcurses
e2beda18 3CFLAGS = -Wall
82e78006 4DFLAGS = -g -DDEBUG
b801d8b2 5PROGS = tig
b8ae9346 6DOCS = tig.1.txt tig.1.html tig.1 README.html
e2beda18
JF
7
8ifneq (,$(wildcard .git))
9CFLAGS += '-DVERSION="$(shell git-describe)"'
10endif
800a900c 11
a7bc4b14 12all: $(PROGS)
82e78006
JF
13all-debug: $(PROGS)
14all-debug: CFLAGS += $(DFLAGS)
a7bc4b14 15docs: $(DOCS)
800a900c 16
05f1685b 17install: all
a7bc4b14 18 for prog in $(PROGS); do \
4c6fabc2
JF
19 install $$prog $(PREFIX)/bin; \
20 done
21
22install-docs: docs
23 for doc in $(DOCS); do \
24 case "$$doc" in \
25 *.1) install $$doc $(PREFIX)/man/man1 ;; \
26 esac \
a7bc4b14 27 done
05f1685b
JF
28
29clean:
8855ada4 30 rm -f $(PROGS) $(DOCS) core
05f1685b 31
57bdf034
JF
32spell-check:
33 aspell --lang=en --check tig.1.txt
34
b801d8b2 35.PHONY: all docs install clean
a7bc4b14 36
b801d8b2
JF
37tig: tig.c
38
39tig.1.txt: tig.c
b76c2afc
JF
40 sed -n '/\/\*\*/,/\*\*\//p' < $< | \
41 sed 's/.*\*\*\///' | \
42 sed '/^[^*]*\*\*/d' | \
b801d8b2 43 sed 's/\*\///;s/^[^*]*\* *//' > $@
a7bc4b14 44
b8ae9346
JF
45README.html: README
46 asciidoc -b xhtml11 -d article -f web.conf $<
47
a7bc4b14 48%.1.html : %.1.txt
4c6fabc2 49 asciidoc -b xhtml11 -d manpage $<
a7bc4b14
JF
50
51%.1.xml : %.1.txt
4c6fabc2 52 asciidoc -b docbook -d manpage $<
a7bc4b14
JF
53
54%.1 : %.1.xml
55 xmlto man $<