Skip to content

Commit 69a5dcc

Browse files
committed
Fix make release
1 parent 7e161c4 commit 69a5dcc

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

Makefile

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,17 @@ precompile:
2828

2929
# Make static-linked binaries and tarballs
3030
release: $(SRC)
31-
rm -r $(DIST_DIR)
31+
rm -fr $(DIST_DIR)
3232
@for os in $(RELEASE_OS); do \
3333
for arch in $(RELEASE_ARCH); do \
34-
echo "Making binary for ... os=$$os, arch=$$arch"; \
3534
if [ $$os = windows ]; then \
36-
GOOS=$$os GOARCH=$$arch go build -tags netgo -installsuffix netgo -ldflags "$(RELEASE_LDFLAGS)" -o $(DIST_DIR)/$(NAME)-$(VERSION)-$$os-$$arch.exe; \
35+
exe=$(DIST_DIR)/$(NAME)-$(VERSION)-$$os-$$arch.exe; \
36+
echo "Creating $$exe ... (os=$$os, arch=$$arch)"; \
37+
GOOS=$$os GOARCH=$$arch go build -tags netgo -installsuffix netgo -ldflags "$(RELEASE_LDFLAGS)" -o $$exe; \
3738
else \
38-
GOOS=$$os GOARCH=$$arch go build -tags netgo -installsuffix netgo -ldflags "$(RELEASE_LDFLAGS)" -o $(DIST_DIR)/$(NAME)-$(VERSION)-$$os-$$arch; \
39+
exe=$(DIST_DIR)/$(NAME)-$(VERSION)-$$os-$$arch; \
40+
echo "Creating $$exe ... (os=$$os, arch=$$arch)"; \
41+
GOOS=$$os GOARCH=$$arch go build -tags netgo -installsuffix netgo -ldflags "$(RELEASE_LDFLAGS)" -o $$exe; \
3942
strip $(DIST_DIR)/$(NAME)-$(VERSION)-$$os-$$arch 2>/dev/null; \
4043
true; \
4144
fi; \

0 commit comments

Comments
 (0)