iot_cloud/go_extend/Makefile
2026-06-01 14:31:15 +08:00

17 lines
337 B
Makefile

GO ?= go
GOCACHE ?= /private/tmp/go-build-cache
BINARY ?= iot_ctrl
GO_LDFLAGS ?= -linkmode=external
.PHONY: build
build:
GOCACHE=$(GOCACHE) $(GO) build -ldflags="$(GO_LDFLAGS)" -o $(BINARY) ./cmd/iot_ctrl
.PHONY: test
test:
GOCACHE=$(GOCACHE) $(GO) test -ldflags="$(GO_LDFLAGS)" ./cmd/iot_ctrl
.PHONY: clean
clean:
rm -f $(BINARY)