2021-08-21 08:19:49 +00:00
|
|
|
PREFIX ?= /usr/local
|
|
|
|
BIN_PREFIX = $(DESTDIR)$(PREFIX)/bin
|
|
|
|
SERVICE_PREFIX = $(DESTDIR)$(PREFIX)/lib/systemd/user
|
|
|
|
CFG_PREFIX = $(DESTDIR)/etc
|
|
|
|
|
|
|
|
all:
|
2021-08-21 23:03:54 +00:00
|
|
|
go build $(GOFLAGS)
|
|
|
|
go build ./cmd/itctl $(GOFLAGS)
|
2021-08-21 08:19:49 +00:00
|
|
|
|
|
|
|
install:
|
|
|
|
install -Dm755 ./itd $(BIN_PREFIX)/itd
|
|
|
|
install -Dm755 ./itctl $(BIN_PREFIX)/itctl
|
|
|
|
install -Dm644 ./itd.service $(SERVICE_PREFIX)/itd.service
|
|
|
|
install -Dm644 ./itd.toml $(CFG_PREFIX)/itd.toml
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f itctl
|
|
|
|
rm -f itd
|
|
|
|
|
|
|
|
.PHONY: all install clean
|