File: rules

package info (click to toggle)
augur 24.4.0-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 25,312 kB
  • sloc: python: 14,253; sh: 227; makefile: 35
file content (27 lines) | stat: -rwxr-xr-x 904 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
23
24
25
26
27
#!/usr/bin/make -f

# DH_VERBOSE := 1
export LC_ALL=C.UTF-8
export PYBUILD_TEST_ARGS=-k 'not (test_mypy or test_flake8)'

%:
	dh $@ --with python3 --buildsystem=pybuild

override_dh_install:
	dh_install
	find debian -name LICENSE.txt -delete
	find debian -name '*.fasta' -delete
	$(RM) -r debian/augur/usr/lib/python3.*/dist-packages/.mypy_cache

override_dh_auto_clean:
	dh_auto_clean
	rm -rf .pytest_cache nextstrain_augur.egg-info

# The below hoops are required for the tests involving mypy and flake8.
BUILD_DIRS := $(wildcard $(CURDIR)/.pybuild/cpython*_*/build)
execute_before_dh_auto_test:
	$(foreach build_dir,$(BUILD_DIRS), cp -v mypy.ini $(build_dir) &&) :
	$(foreach build_dir,$(BUILD_DIRS), cp -v .flake8 $(build_dir) &&) :
execute_after_dh_auto_test:
	$(foreach build_dir,$(BUILD_DIRS), rm -v $(build_dir)/mypy.ini &&) :
	$(foreach build_dir,$(BUILD_DIRS), rm -v $(build_dir)/.flake8 &&) :