Makefile 732 Bytes
NAME = colab-deps
VERSION = 1.10
PREFIX = /usr
TARGET = $(DESTDIR)$(PREFIX)/lib/colab

all:
	rm -rf ./build
	virtualenv ./build
	./build/bin/pip install --no-index --find-links=$(CURDIR) -r requirements.txt
	./build/bin/pip install pip-1.5.6.tar.gz
	virtualenv --relocatable ./build

clean:
	$(RM) -r ./build

SOURCES = Makefile requirements.txt *.tar.* *.zip

install:
	mkdir -p $$(dirname $(TARGET))
	rm -rf $(TARGET)
	cp -r ./build $(TARGET)

DISTDIR = $(NAME)-$(VERSION)
TARBALL = dist/$(DISTDIR).tar.gz

sdist: $(TARBALL)

$(TARBALL):
	mkdir -p $$(dirname $(TARBALL))
	$(RM) $(TARBALL)
	mkdir $(DISTDIR)
	ln $(SOURCES) $(DISTDIR)
	tar caf $(TARBALL) $(DISTDIR)
	$(RM) -r $(DISTDIR)

distclean:
	$(RM) -r $$(dirname $(TARBALL))