#!/usr/bin/make -f
# -*- makefile -*-
# Sample debian/rules that uses debhelper.
# This file was originally written by Joey Hess and Craig Small.
# As a special exception, when this file is copied by dh-make into a
# dh-make output file, you may use that output file without restriction.
# This special exception was added by Craig Small in version 0.37 of dh-make.

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

#./validate  test failed,have report it to upstream

%:
	dh  $@

override_dh_auto_clean:
	./configure   #Makefile from upstream, need to delete
	              # workaround it
	dh_auto_clean

override_dh_auto_configure:
	./configure
	#link against tclstub and tkstub to make it work with multi version of tcl/tk
	#bug:#620093
	sed -i "s/-ltk\([0-9].[0-9]\)/-ltk\1 -ltkstub\1/" Makefile
	sed -i "s/-ltcl\([0-9].[0-9]\)/-ltcl\1 -ltclstub\1/" Makefile

override_dh_auto_test:
#	./validate
#	need display

override_dh_auto_install:

override_dh_installchangelogs:
	dh_installchangelogs CHANGES.html

