diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 17:45:10 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 17:45:10 +0000 |
commit | 8ffdcdb6f6cd595c9efedd0d02e351e88c19147b (patch) | |
tree | e12756d71ec73654e58151fd2872cfc50456d5e0 /debian/rules | |
parent | Adding upstream version 0.10.1. (diff) | |
download | python-netaddr-debian.tar.xz python-netaddr-debian.zip |
Adding debian version 0.10.1-1.debian/0.10.1-1debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rwxr-xr-x | debian/rules | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..cbf6dc7 --- /dev/null +++ b/debian/rules @@ -0,0 +1,29 @@ +#!/usr/bin/make -f +# -*- mode: makefile; coding: utf-8 -*- + +export PYBUILD_NAME=netaddr +export LC_ALL=C.UTF-8 + +%: + dh $@ --with python3 --buildsystem=pybuild + +# Replace EUI files with the appropriate symlinks +override_dh_link: dh_link/python3-netaddr + dh_link +python_module_path=usr/lib/python*/dist-packages +dh_link/python3-netaddr: + rm debian/$(@:dh_link/%=%)/$(python_module_path)/netaddr/eui/iab.* + rm debian/$(@:dh_link/%=%)/$(python_module_path)/netaddr/eui/oui.* + ln -s /var/lib/ieee-data/oui.txt debian/$(@:dh_link/%=%)/$(python_module_path)/netaddr/eui/ + ln -s /var/lib/ieee-data/iab.txt debian/$(@:dh_link/%=%)/$(python_module_path)/netaddr/eui/ + PYTHONPATH=$(CURDIR) python3 \ + debian/$(@:dh_link/%=%)/$(python_module_path)/netaddr/eui/ieee.py + +override_dh_python3: + dh_python3 --shebang=/usr/bin/python3 + +# Tests +override_dh_auto_test: + localehelper LANG=en_US.UTF-8 dh_auto_test -- \ + --system=custom \ + --test-args='{interpreter} -m pytest netaddr/tests -v' |