github.com/avvmoto/glide@v0.12.3/Makefile (about) 1 GLIDE_GO_EXECUTABLE ?= go 2 VERSION := $(shell git describe --tags) 3 DIST_DIRS := find * -type d -exec 4 5 build: 6 ${GLIDE_GO_EXECUTABLE} build -o glide -ldflags "-X main.version=${VERSION}" glide.go 7 8 install: build 9 install -d ${DESTDIR}/usr/local/bin/ 10 install -m 755 ./glide ${DESTDIR}/usr/local/bin/glide 11 12 test: 13 ${GLIDE_GO_EXECUTABLE} test . ./gb ./path ./action ./tree ./util ./godep ./godep/strip ./gpm ./cfg ./dependency ./importer ./msg ./repo ./mirrors 14 15 integration-test: 16 ${GLIDE_GO_EXECUTABLE} build 17 ./glide up 18 ./glide install 19 20 clean: 21 rm -f ./glide.test 22 rm -f ./glide 23 rm -rf ./dist 24 25 bootstrap-dist: 26 ${GLIDE_GO_EXECUTABLE} get -u github.com/franciscocpg/gox 27 cd ${GOPATH}/src/github.com/franciscocpg/gox && git checkout dc50315fc7992f4fa34a4ee4bb3d60052eeb038e 28 cd ${GOPATH}/src/github.com/franciscocpg/gox && ${GLIDE_GO_EXECUTABLE} install 29 30 31 build-all: 32 gox -verbose \ 33 -ldflags "-X main.version=${VERSION}" \ 34 -os="linux darwin windows freebsd openbsd netbsd" \ 35 -arch="amd64 386 armv5 armv6 armv7 arm64" \ 36 -osarch="!darwin/arm64" \ 37 -output="dist/{{.OS}}-{{.Arch}}/{{.Dir}}" . 38 39 dist: build-all 40 cd dist && \ 41 $(DIST_DIRS) cp ../LICENSE {} \; && \ 42 $(DIST_DIRS) cp ../README.md {} \; && \ 43 $(DIST_DIRS) tar -zcf glide-${VERSION}-{}.tar.gz {} \; && \ 44 $(DIST_DIRS) zip -r glide-${VERSION}-{}.zip {} \; && \ 45 cd .. 46 47 48 .PHONY: build test install clean bootstrap-dist build-all dist integration-test