From 6c920e0925c5b9db4354c31a693140adf024d88b Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Fri, 15 Nov 2024 01:22:47 -0600 Subject: stub'd out --- Makefile | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..9d275bc --- /dev/null +++ b/Makefile @@ -0,0 +1,39 @@ +VERSION = $(shell git describe --tags) + +# create the go.mod and go.sum if this is a brand new repo +# REDOMOD = $(shell if [ -e go.mod ]; then echo go.mod; else echo no go mod; fi) +REDOMOD = $(shell if [ -e go.sum ]; then echo go.sum exists; else GO111MODULE= go mod init; GO111MODULE= go mod tidy; fi) + +all: + GO111MODULE=off go build -v -x -ldflags "-X main.VERSION=${VERSION} -X gui.GUIVERSION=${VERSION}" + #./zood + ./zood --version + +# this is for release builds using the go.mod files +release-build: + @echo ${REDOMOD} + go build -v -ldflags "-X main.VERSION=${VERSION} -X gui.GUIVERSION=${VERSION}" + +# makes a .deb package +debian: + go-deb --no-gui --repo go.wit.com/lib/daemons/zood + +goimports: + goimports -w *.go + +redomod: + rm -f go.* + GO111MODULE= go mod init + GO111MODULE= go mod tidy + +clean: + rm -f go.* + rm -f zood + +# git clone the sources and all the golang dependancies into ~/go/src +# if you don't have go-clone, you can get it from http://go.wit.com/ +git-clone: + go-clone --recursive go.wit.com/lib/daemons/zood + +http-list-packages: + curl --silent http://localhost:2521/list?hostname=zookeeper.wit.com -- cgit v1.2.3