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.

30 lines
785 B

.PHONY: clean
VERSION :=v1.7.1
GITEA_SRC :=gitea-src-$(VERSION)
GOPATH :=$(shell pwd)/$(GITEA_SRC)/.go
all: gitea
gitea: $(GITEA_SRC) checkout-version $(GOPATH) $(GOPATH)/bin/go-bindata
cd $(GOPATH)/src/\
&& PATH=$(GOPATH)/bin:$$PATH TAGS=$(GITEA_BUILD_TAGS) make generate build
cp $(GITEA_SRC)/$@ $@
mkdir -p $@/src/
ln -sf $(shell pwd)/$(GITEA_SRC) $(GOPATH)/src/
$(GOPATH)/bin/go-bindata: $(GOPATH)
go get
git clone $@
checkout-version: $(GITEA_SRC)
cd $(GITEA_SRC) && git checkout --force --quiet $(VERSION)
rm -f gitea
rm -rf gitea-*