clean build rules
This commit is contained in:
parent
3125ca435d
commit
4a36e0300b
16
Makefile
16
Makefile
|
@ -1,15 +1,19 @@
|
||||||
VERSION = $(shell git describe --tags)
|
VERSION = $(shell git describe --tags)
|
||||||
|
BUILDTIME = $(shell date +%Y.%m.%d)
|
||||||
|
|
||||||
all: plugin
|
all:nocui.so
|
||||||
ldd ../nocui.so
|
@#ldd nocui.so
|
||||||
|
|
||||||
plugin:
|
nocui.so:
|
||||||
GO111MODULE=off go build -buildmode=plugin -o nocui.so
|
GO111MODULE=off go build -v -buildmode=plugin -o nocui.so \
|
||||||
|
-ldflags "-X main.VERSION=${VERSION} -X main.BUILDTIME=${BUILDTIME} -X gui.GUIVERSION=${VERSION}"
|
||||||
|
|
||||||
install:
|
install: clean
|
||||||
rm -f nocui.so
|
|
||||||
go build -buildmode=plugin -o ~/go/lib/nocui-${VERSION}.so
|
go build -buildmode=plugin -o ~/go/lib/nocui-${VERSION}.so
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -f nocui.so
|
||||||
|
|
||||||
check-git-clean:
|
check-git-clean:
|
||||||
@git diff-index --quiet HEAD -- || (echo "Git repository is dirty, please commit your changes first"; exit 1)
|
@git diff-index --quiet HEAD -- || (echo "Git repository is dirty, please commit your changes first"; exit 1)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue