comparison Makefile @ 66:787b5ee0289d draft

Use vendored modules Signed-off-by: Izuru Yakumo <yakumo.izuru@chaotic.ninja>
author yakumo.izuru
date Sun, 23 Jul 2023 13:18:53 +0000
parents 315dee06253e
children 4edfa07d5fe0
comparison
equal deleted inserted replaced
65:6d985efa0f7a 66:787b5ee0289d
1 destdir ?= 1 DESTDIR ?=
2 goflags ?= -v -ldflags "-w -X `go list`.Version=$(version) -X `go list`.Commit=$(commit)" -tags "static_build" 2 GOFLAGS ?= -v -ldflags "-w -X `go list`.Version=$(VERSION) -X `go list`.Commit=$(COMMIT)" -tags "static_build" -mod=vendor
3 prefix ?= /usr/local 3 PREFIX ?= /usr/local
4 version ?= `git describe --abbrev=0 --tags || echo "$version"` 4 VERSION ?= `git describe --abbrev=0 --tags || echo "$VERSION"`
5 commit ?= `git rev-parse --short HEAD || echo "$commit"` 5 COMMIT ?= `git rev-parse --short HEAD || echo "$COMMIT"`
6 6
7 7
8 build: 8 build:
9 go build ${goflags} ./cmd/aya 9 go build ${GOFLAGS} ./cmd/aya
10 clean: 10 clean:
11 rm -f aya 11 rm -f aya
12 install: 12 install:
13 install -Dm0755 aya ${destdir}${prefix}/bin/aya 13 install -Dm0755 aya ${DESTDIR}${PREFIX}/bin/aya
14 install -Dm0644 aya.1 ${destdir}${prefix}/share/man/man1/aya.1 14 install -Dm0644 aya.1 ${DESTDIR}${PREFIX}/share/man/man1/aya.1
15 uninstall: 15 uninstall:
16 rm -f ${prefix}/bin/aya 16 rm -f ${PREFIX}/bin/aya
17 rm -f ${prefix}/share/man/man1/aya.1 17 rm -f ${PREFIX}/share/man/man1/aya.1