Skip to content

Commit f35c069

Browse files
committed
Add oasis.exe rule and fix Makefile
Add oasis.exe rule Remove .exe extension which is handled by goreleaser Move build-windows phony target Change release-build option to previous version
1 parent 782497c commit f35c069

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

.goreleaser.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ builds:
6060
- arm64
6161
- <<: *build-common
6262
id: oasis-windows-amd64
63-
binary: oasis.exe
63+
binary: oasis
6464
env:
6565
- CC=x86_64-w64-mingw32-gcc
6666
- CXX=x86_64-w64-mingw32-g++

Makefile

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,16 @@ all: build
1414
# Build.
1515
build: oasis
1616

17-
build-windows: $(shell find . -name "*.go" -type f) go.sum go.mod
18-
@$(PRINT) "$(MAGENTA)*** Building for Windows...$(OFF)\n"
19-
GOOS=windows GOARCH=amd64 $(GO) build -v -o oasis.exe $(GOFLAGS) $(GO_EXTRA_FLAGS)
17+
build-windows: oasis.exe
2018

2119
oasis: $(shell find . -name "*.go" -type f) go.sum go.mod
2220
@$(PRINT) "$(MAGENTA)*** Building Go code...$(OFF)\n"
2321
@$(GO) build -v -o oasis $(GOFLAGS) $(GO_EXTRA_FLAGS)
2422

23+
oasis.exe: $(shell find . -name "*.go" -type f) go.sum go.mod
24+
@$(PRINT) "$(MAGENTA)*** Building for Windows...$(OFF)\n"
25+
GOOS=windows GOARCH=amd64 $(GO) build -v -o oasis.exe $(GOFLAGS) $(GO_EXTRA_FLAGS)
26+
2527
examples: $(EXAMPLES)
2628

2729
examples/%.out: examples/%.in oasis scripts/gen_example.sh
@@ -82,10 +84,10 @@ clean:
8284
# List of targets that are not actual files.
8385
.PHONY: \
8486
all build \
87+
build-windows \
8588
examples \
8689
clean-examples \
8790
fmt \
8891
$(lint-targets) lint \
8992
$(test-targets) test \
9093
clean
91-
windows

0 commit comments

Comments
 (0)