#!/usr/bin/make -f

ifeq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
	export DEB_CFLAGS_MAINT_APPEND= -ffast-math
endif

%:
	dh $@ --with autoreconf --parallel

override_dh_auto_configure:
	dh_auto_configure -- -with-exiv2 --enable-extras --enable-mime \
		--enable-contrast


override_dh_auto_build:
	dh_auto_build
	# rename ufraw.1 to ufraw-batch.1, since we're installing it in the ufraw-batch package
	mv ufraw.1 ufraw-batch.1

override_dh_auto_install:
	dh_auto_install
	#rm $(CURDIR)/debian/ufraw/usr/bin/dcraw

#	remove the dcraw binary, since it's in the dcraw package
##	rm $(CURDIR)/debian/ufraw/usr/bin/dcraw

# Build architecture-dependent files here.
binary-arch: build install
#	rename ufraw.1 to ufraw-batch.1, since we're installing it in the ufraw-batch package
##	mv $(CURDIR)/debian/ufraw-batch/usr/share/man/man1/ufraw.1 $(CURDIR)/debian/ufraw-batch/usr/share/man/man1/ufraw-batch.1
