Makefile
PREFIX := /usr/local BINDIR := $(PREFIX)/bin SRCS := main.go VERSION := 0.1.0 .PHONY: all all: nshc-form nshc-form: $(SRCS) CGO_ENABLED=0 go build -ldflags="-s -w -X main.Version=$(VERSION)" -o $@ .PHONY: install install: nshc-form mkdir -p $(BINDIR) install -m 0755 $< $(BINDIR) .PHONY: clean clean: rm nshc-form