I am trying to create a simple Makefile for my go project.
The following command substitution
GO_BUILD := 'go build -ldflags "-s -w" -a -installsuffix cgo'
.PHONY: backup
build-cli:
@$(GO_BUILD) -o cli ./cli
seems to create the following problem
▶ make build-cli
make: go build -ldflags "-s -w" -a -installsuffix cgo: No such file or directory
make: *** [build-cli] Error 1
What is the syntactically correct way of substituting go build -ldflags "-s -w" -a -installsuffix cgo ?