On go1.20+ it is no longer possible to directly copy a cgo-enabled library into a docker container. For this reason, this commit adds a flag to commands that automatically make them fail with an appropriate message if cgo is enabled.
15 lines
No EOL
328 B
Makefile
15 lines
No EOL
328 B
Makefile
.PHONY: clean all deps
|
|
|
|
all: wdcli
|
|
|
|
wdcli:
|
|
go generate ./internal/dis/component/control/static/
|
|
CGO_ENABLED=0 go build -o ./wdcli ./cmd/wdcli
|
|
|
|
deps: internal/dis/component/server/assets/node_modules
|
|
|
|
internal/dis/component/server/assets/node_modules:
|
|
cd internal/dis/component/server/assets/ && yarn install
|
|
|
|
clean:
|
|
rm wdcli
|