File: rules

package info (click to toggle)
bzr-search 1.7.0~bzr94-5
  • links: PTS, VCS
  • area: main
  • in suites:
  • size: 428 kB
  • sloc: python: 2,402; makefile: 14; sh: 1
file content (18 lines) | stat: -rwxr-xr-x 673 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/bin/make -f

%:
	dh "$@" --with python2 --buildsystem=python_distutils

ifeq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
override_dh_auto_test:
	BZR_PLUGINS_AT=search@$(CURDIR) /usr/bin/bzr selftest -s bp.search
endif

PACKAGE = bzr-search
SRC_VERSION := $(shell dpkg-parsechangelog | sed -ne 's/^Version: \(\([0-9]\+\):\)\?\(.*\)-.*/\3/p')
BZR_REVISION := $(shell echo $(SRC_VERSION) | awk -F"~" '{ print $$2 }' | sed 's/bzr//' )
TARBALL = $(PACKAGE)_$(SRC_VERSION).orig.tar.gz
.PHONY: get-orig-source
get-orig-source:
	bzr export $(TARBALL) -r $(BZR_REVISION) "lp:bzr-search"
	echo "  "$(TARBALL)" created; move it to the right destination to build the package"