You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
377 B

  1. BINARY = weed
  2. GO_FLAGS = #-v
  3. SOURCE_DIR = ./go/weed/
  4. all: build
  5. .PHONY : clean deps build linux
  6. clean:
  7. go clean -i $(GO_FLAGS) $(SOURCE_DIR)
  8. rm -f $(BINARY)
  9. deps:
  10. go get $(GO_FLAGS) -d $(SOURCE_DIR)
  11. build: deps
  12. go build $(GO_FLAGS) -o $(BINARY) $(SOURCE_DIR)
  13. linux: deps
  14. mkdir -p linux
  15. GOOS=linux GOARCH=amd64 go build $(GO_FLAGS) -o linux/$(BINARY) $(SOURCE_DIR)