#!/usr/bin/make -f

include /usr/share/dpkg/default.mk

override_dh_auto_install:
	cd obj-$(DEB_TARGET_GNU_TYPE); \
	for bin in server client; do \
		mv bin/$$bin bin/kcptun-$$bin; \
		help2man -N -n "Simple UDP Tunnel Based On KCP" \
			--version-string="$(DEB_VERSION)" \
			-o kcptun-$$bin.1 bin/kcptun-$$bin; \
	done
	dh_auto_install

%:
	dh $@ --buildsystem=golang --with=golang
