#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

export PYBUILD_NAME = ldap
export PYBUILD_DISABLE=test

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

override_dh_strip:
	dh_strip -ppython3-ldap --dbgsym-migration='python3-ldap-dbg (<< 3.3.1-1~)'

override_dh_sphinxdoc:
ifeq (,$(findstring nodoc, $(DEB_BUILD_OPTIONS)))
	PYTHONPATH=. python3 -m sphinx -b html -N Doc $(CURDIR)/debian/python-ldap-doc/usr/share/doc/python-ldap-doc/html
	dh_sphinxdoc
endif
