File: rules

package info (click to toggle)
fiona 1.8.18-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 1,748 kB
  • sloc: python: 8,701; makefile: 177; sh: 145
file content (62 lines) | stat: -rwxr-xr-x 2,602 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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#!/usr/bin/make -f

# Enable hardening build flags
export DEB_BUILD_MAINT_OPTIONS=hardening=+all

export LC_ALL=C.UTF-8
export LANG=C.UTF-8

BUILD_DATE=$(shell LC_ALL=C date -u "+%B %d, %Y" -d "@$(SOURCE_DATE_EPOCH)")

DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)

export PYBUILD_NAME=fiona
export PYBUILD_AFTER_BUILD_python3 = mkdir -p doc-build && cd doc-build && PYTHONPATH={build_dir} http_proxy='127.0.0.1:9' python{version} -m sphinx -N -bhtml -D today="$(BUILD_DATE)" ../docs/ ../build/html
export PYBUILD_TEST_PYTEST=1
export PYBUILD_BEFORE_TEST=cp -r {dir}/tests {build_dir}
export PYBUILD_AFTER_TEST=rm -rf {build_dir}/tests
export PYBUILD_TEST_ARGS=--ignore tests/test_bytescollection.py \
                         --ignore tests/test_collection.py \
                         --ignore tests/test_data_paths.py \
                         --ignore tests/test_feature.py \
                         --ignore tests/test_filter_vsi.py \
                         --ignore tests/test_fio_bounds.py \
                         --ignore tests/test_fio_calc.py \
                         --ignore tests/test_fio_cat.py \
                         --ignore tests/test_fio_collect.py \
                         --ignore tests/test_fio_distrib.py \
                         --ignore tests/test_fio_dump.py \
                         --ignore tests/test_fio_filter.py \
                         --ignore tests/test_fio_info.py \
                         --ignore tests/test_fio_load.py \
                         --ignore tests/test_fio_ls.py \
                         --ignore tests/test_fio_rm.py \
                         --ignore tests/test_geopackage.py \
                         --ignore tests/test_layer.py \
                         --ignore tests/test_listing.py \
                         --ignore tests/test_profile.py \
                         --ignore tests/test_unicode.py \
                         --ignore tests/test_vfs.py

%:
	dh  $@ --with python3,sphinxdoc --buildsystem pybuild

override_dh_clean:
	dh_clean
	rm -rf fiona/*.so gdal-config.txt fiona/*.c VERSION.txt fiona/*.cpp Fiona.egg-info/
	rm -rf doc-build

override_dh_auto_test:
# Ignore test failures on problematic architectures only
ifneq (,$(filter $(DEB_BUILD_ARCH),hurd-i386 kfreebsd-amd64 kfreebsd-i386 ppc64))
	dh_auto_test || echo "Ignoring test failures"
else
	dh_auto_test
endif

override_dh_install:
	dh_install --list-missing
	rm -rf debian/python3-fiona/usr/bin

debian/fiona.1:
	help2man fiona -N -L en_US.utf8 -n "command line tools for reading/writing geospatial vector data" >debian/fiona.1