#!/usr/bin/make -f
# -*- makefile -*-

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
BUILD_DATE := $(shell TZ=UTC LC_ALL=C dpkg-parsechangelog | grep Date: | cut -d' ' -f2-7)
export TZ=UTC
export LC_ALL=C
export BDATE=$(shell TZ=UTC LC_ALL=C date -d"$(BUILD_DATE)" +'%b %d %Y')
export BTIME=$(shell TZ=UTC LC_ALL=C date -d"$(BUILD_DATE)" +'%T')

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

%:
	dh $@ --no-parallel

#override_dh_auto_build:
#	cd standardPregraph && make 63mer=1
#	cd standardPregraph && make 127mer=1
#	cd sparsePregraph && make
#	dh_auto_build

override_dh_install:
	dh_install
	cd debian/soapdenovo2/usr/bin/;rename 's/SOAPdenovo/soapdenovo2/' SOAP*

override_dh_clean:
	cd standardPregraph && make 63mer=1 clean && make 127mer=1 clean
	cd sparsePregraph && make clean
	dh_clean
