| 1 |
#!/usr/bin/make -f |
| 2 |
|
| 3 |
D= ${CURDIR}/debian |
| 4 |
DTMP= $D/tmp |
| 5 |
PY= ${CURDIR}/python |
| 6 |
|
| 7 |
RS= ${CURDIR}/rust |
| 8 |
RS_TGT= ${RS}/target/release |
| 9 |
RS_BIN= ${RS_TGT}/feature-check |
| 10 |
|
| 11 |
export PYBUILD_NAME= feature_check |
| 12 |
export PYBUILD_DIR= ${PY} |
| 13 |
export PYBUILD_TEST_PYTEST= 1 |
| 14 |
export PYTEST_ADDOPTS= ${PY}/tests/unit |
| 15 |
|
| 16 |
%: |
| 17 |
dh "$@" |
| 18 |
|
| 19 |
execute_after_dh_auto_build-arch: |
| 20 |
mkdir -p rust/.cargo |
| 21 |
install -m 644 -- '$D/cargo-config.toml' '${RS}/.cargo/config.toml' |
| 22 |
{ \ |
| 23 |
set -e; \ |
| 24 |
cd -- '${RS}'; \ |
| 25 |
cargo build --release; \ |
| 26 |
} |
| 27 |
|
| 28 |
execute_after_dh_auto_build-indep: |
| 29 |
dh_auto_build --buildsystem pybuild |
| 30 |
|
| 31 |
override_dh_auto_install-arch: |
| 32 |
dh_auto_install -- \ |
| 33 |
PREFIX=/usr \ |
| 34 |
MANDIR=/usr/share/man/man \ |
| 35 |
INSTALL_SCRIPT='install -m 755' \ |
| 36 |
INSTALL_DATA='install -m 644' |
| 37 |
|
| 38 |
install -m 755 -- '${RS_BIN}' '${DTMP}/usr/bin/feature-check' |
| 39 |
|
| 40 |
override_dh_auto_install-indep: |
| 41 |
dh_auto_install --buildsystem pybuild |
| 42 |
|
| 43 |
execute_after_dh_auto_test-arch: |
| 44 |
${MAKE} test-single TEST_PROG='${RS_BIN}' |
| 45 |
|
| 46 |
execute_after_dh_auto_test-indep: |
| 47 |
env PYTHONPATH='${PY}/src' debian/tests/tappy.py |
| 48 |
# dh_auto_test --buildsystem pybuild |
| 49 |
|
| 50 |
override_dh_installchangelogs: |
| 51 |
dh_installchangelogs -X changes.md |
| 52 |
|
| 53 |
execute_after_dh_installchangelogs-arch: |
| 54 |
install -m 644 -- docs/changes.md '$D/feature-check/usr/share/doc/feature-check/NEWS' |
| 55 |
|
| 56 |
execute_after_dh_auto_clean-indep: |
| 57 |
dh_auto_clean --buildsystem pybuild |