#!/usr/bin/make -f

export DEB_LDFLAGS_MAINT_APPEND = -lvorbis -logg -lm

ifeq "$(DEB_BUILD_ARCH)" "arm64"
	export DEB_CFLAGS_MAINT_APPEND = -mbranch-protection=standard
endif

%:
	dh $@ --with quilt

override_dh_auto_configure:
	dh_auto_configure -- \
	--program-transform-name="s/ices$$/ices2/"
#	exit 1

override_dh_install:
	dh_installdirs usr/share/doc/ices2/html
	mv debian/ices2/usr/share/ices/* debian/ices2/usr/share/doc/ices2/html
	rmdir debian/ices2/usr/share/ices

	dh_install
