Makefile
author Pierre-Yves David <pierre-yves.david@logilab.fr>
Wed, 29 Aug 2012 11:36:10 +0200
branchstable
changeset 531 b18b00036355
parent 0 bbeef801409c
child 542 ca5bb72d14ae
permissions -rw-r--r--
pkg/debian: Debian packaging This change add the necessary files to create a debian package for the evolve extension. I do not care about the rest.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
     1
PYTHON=python
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
     2
HG=`which hg`
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
     3
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
     4
help:
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
     5
	@echo 'Commonly used make targets:'
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
     6
	@echo '  tests              - run all tests in the automatic test suite'
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
     7
	@echo '  all-version-tests - run all tests against many hg versions'
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
     8
	@echo '  tests-%s           - run all tests in the specified hg version'
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
     9
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    10
all: help
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    11
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    12
tests:
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    13
	cd tests && $(PYTHON) run-tests.py --with-hg=$(HG) $(TESTFLAGS)
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    14
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    15
test-%:
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    16
	cd tests && $(PYTHON) run-tests.py --with-hg=$(HG) $(TESTFLAGS) $@
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    17
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    18
tests-%:
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    19
	@echo "Path to crew repo is $(CREW) - set this with CREW= if needed."
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    20
	hg -R $(CREW) checkout $$(echo $@ | sed s/tests-//) && \
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    21
	(cd $(CREW) ; $(MAKE) clean ) && \
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    22
	cd tests && $(PYTHON) $(CREW)/tests/run-tests.py $(TESTFLAGS)
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    23
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    24
all-version-tests: tests-1.3.1 tests-1.4.3 tests-1.5.4 \
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    25
                   tests-1.6.4 tests-1.7.5 tests-1.8 tests-tip
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    26
531
b18b00036355 pkg/debian: Debian packaging
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 0
diff changeset
    27
deb-prepare:
b18b00036355 pkg/debian: Debian packaging
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 0
diff changeset
    28
	python setup.py sdist --dist-dir ..
b18b00036355 pkg/debian: Debian packaging
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 0
diff changeset
    29
	mv -f ../hg-evolve-1.0.0.tar.gz ../mercurial-evolve_1.0.0.orig.tar.gz
b18b00036355 pkg/debian: Debian packaging
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 0
diff changeset
    30
	tar xf ../mercurial-evolve_1.0.0.orig.tar.gz
b18b00036355 pkg/debian: Debian packaging
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 0
diff changeset
    31
	rm -rf ../mercurial-evolve_1.0.0.orig
b18b00036355 pkg/debian: Debian packaging
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 0
diff changeset
    32
	mv hg-evolve-1.0.0 ../mercurial-evolve_1.0.0.orig
b18b00036355 pkg/debian: Debian packaging
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 0
diff changeset
    33
	cp -r debian/ ../mercurial-evolve_1.0.0.orig/
b18b00036355 pkg/debian: Debian packaging
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 0
diff changeset
    34
	@cd ../mercurial-evolve_1.0.0.orig && echo 'debian build directory ready at' `pwd`
b18b00036355 pkg/debian: Debian packaging
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 0
diff changeset
    35
0
bbeef801409c minimalistic state concept.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents:
diff changeset
    36
.PHONY: tests all-version-tests