File: rules

package info (click to toggle)
bandit 1.5.1-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,800 kB
  • sloc: python: 9,953; sh: 42; makefile: 14
file content (22 lines) | stat: -rwxr-xr-x 834 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/usr/bin/make -f

UPSTREAM_GIT = https://github.com/PyCQA/bandit
include /usr/share/openstack-pkg-tools/pkgos.make

%:
	dh $@ --buildsystem=python_distutils --with python2,python3

override_dh_auto_install:
	pkgos-dh_auto_install

	# Generate the config file
	mkdir -p $(CURDIR)/debian/bandit/etc/bandit
	PYTHONPATH=$(CURDIR)/debian/python-bandit/usr/lib/python2.7/dist-packages PATH=$$PATH:$(CURDIR)/debian/bin bandit-config-generator -o $(CURDIR)/debian/bandit/etc/bandit/bandit.yaml

override_dh_python3:
	dh_python3 --shebang=/usr/bin/python3

override_dh_auto_test:
ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS)))
	PATH=$$PATH:$(CURDIR)/debian/bin pkgos-dh_auto_test 'tests\.(?!(.*unit\.cli\.test_baseline\.BanditBaselineToolTests\.test_bandit_baseline.*|.*functional\.test_runtime.*|.*functional\.test_baseline.*))'
endif