~emersion/kimchi

ref: 181313a0aed68d506aac6bc3ebab896382f9a5d9 kimchi/Makefile -rw-r--r-- 591 bytes
181313a0Simon Ser makefile: remove build dep from install target 6 months ago
                                                                                
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
.POSIX:
.SUFFIXES:

GO = go
RM = rm
SCDOC = scdoc
GOFLAGS =
PREFIX = /usr/local
BINDIR = $(PREFIX)/bin
MANDIR = $(PREFIX)/share/man
SYSCONFDIR = /etc

goflags = $(GOFLAGS) \
	-ldflags="-X 'main.configPath=$(SYSCONFDIR)/kimchi/config'"

all: kimchi kimchi.1

kimchi:
	$(GO) build $(goflags) .
kimchi.1:
	$(SCDOC) <kimchi.1.scd >kimchi.1

clean:
	$(RM) -f kimchi kimchi.1

install:
	mkdir -p $(DESTDIR)$(BINDIR)
	mkdir -p $(DESTDIR)$(MANDIR)/man1
	mkdir -p $(DESTDIR)$(SYSCONFDIR)/kimchi
	cp -f kimchi $(DESTDIR)$(BINDIR)
	cp -f kimchi.1 $(DESTDIR)$(MANDIR)/man1

.PHONY: kimchi clean install