~welt/murse

cfb166c0599325f5d0c175f8686ab1f0dfa75bd1 — welt 11 days ago e0a6343 devel
Update Makefile for new packaging.
3 files changed, 38 insertions(+), 5 deletions(-)

M .gitignore
M Makefile
M util.go
M .gitignore => .gitignore +4 -2
@@ 1,5 1,7 @@
test/
murse.exe
murse
./murse
open_fortress/
murse32
murse32.exe
open_fortress
build
\ No newline at end of file

M Makefile => Makefile +34 -2
@@ 1,4 1,36 @@
.POSIX:

VERSION := unknown

default:
	go build -tags netgo -ldflags '-s -w' -o build/linux/murse


release: clean linux linux386 windows windows386 archive
release-sign: clean linux linux386 windows windows386 sign archive

clean:
	rm -rf build 
linux:
	CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -tags netgo -ldflags '-s -w' -o murse
	mkdir -p build/linux/amd64
	CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -tags netgo -ldflags '-s -w' -o build/linux/amd64/murse
linux386:
	mkdir -p build/linux/386
	CGO_ENABLED=0 GOOS=linux GOARCH=386 go build -tags netgo -ldflags '-s -w' -o build/linux/386/murse
windows:
	CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -tags netgo -ldflags "-s -w" -o murse.exe 
	mkdir -p build/windows/amd64
	CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -tags netgo -ldflags "-s -w" -o build/windows/amd64/murse.exe 
windows386:
	mkdir -p build/windows/386
	CGO_ENABLED=0 GOOS=windows GOARCH=386 go build -tags netgo -ldflags "-s -w" -o build/windows/386/murse.exe 
sign:
	gpg --output build/linux/amd64/murse.sig --detach-sig build/linux/amd64/murse
	gpg --output build/linux/386/murse.sig --detach-sig build/linux/386/murse
	gpg --output build/windows/amd64/murse.exe.sig --detach-sig build/windows/amd64/murse.exe
	gpg --output build/windows/386/murse.exe.sig --detach-sig build/windows/386/murse.exe
archive:
	tar czf build/murse-$(VERSION)-linux-amd64.tar.gz build/linux/amd64/*
	tar czf build/murse-$(VERSION)-linux-386.tar.gz build/linux/386/*
	zip build/murse-$(VERSION)-windows-amd64.zip build/windows/amd64/*
	zip build/murse-$(VERSION)-windows-386.zip build/windows/386/*
	
\ No newline at end of file

M util.go => util.go +0 -1
@@ 24,5 24,4 @@ func isExists(dir string) (bool, error) {
	}

	return true, nil

}