#!/usr/bin/make -f

%:
	dh $@

override_dh_auto_configure:

override_dh_auto_build:

override_dh_auto_test:
	./debian/tests/mpfit -l

override_dh_installdocs:
	python debian/idldoc.py
	cp *.html html
	dh_installdocs

override_dh_clean:
	rm -rf html
	dh_clean

get-orig-source:
	wget http://cow.physics.wisc.edu/~craigm/idl/down/mpfit.tar.gz
	mv -f mpfit.tar.gz mpfit_`tar xOf mpfit.tar.gz mpfit.pro|fgrep 'Revision:'|head -1|cut -d: -f2|cut -d\  -f2`+`tar tvf mpfit.tar.gz|grep -Eo '[[:digit:]]{4}-[[:digit:]]{2}-[[:digit:]]{2}'|sort|uniq|tail -1| tr - .`.orig.tar.gz
