mirror of
https://github.com/CosmicStar98/bedrocktool.git
synced 2024-06-26 03:49:45 +00:00
28 lines
447 B
Makefile
28 lines
447 B
Makefile
GC = go build -ldflags "-s -w"
|
|
TAG := $(shell git describe --tags)
|
|
|
|
NAME = bedrocktool_${TAG}
|
|
SRCS = $(wildcard *.go)
|
|
|
|
all: windows linux
|
|
|
|
.PHONY: all clean windows linux mac
|
|
|
|
windows: $(NAME).exe
|
|
linux: $(NAME)-linux
|
|
mac: $(NAME)-mac
|
|
|
|
|
|
$(NAME).exe: $(SRCS)
|
|
echo TAG: ${TAG}
|
|
GOOS=windows $(GC) -o $@
|
|
|
|
$(NAME)-linux: $(SRCS)
|
|
GOOS=linux $(GC) -o $@
|
|
|
|
$(NAME)-mac: $(SRCS)
|
|
GOOS=darwin $(GC) -o $@
|
|
|
|
|
|
clean:
|
|
rm $(NAME).exe $(NAME)-linux $(NAME)-mac
|