The endif doesn't belong to the end of debian/rules. It should only cover DEB_MAKE_CHECK_TARGET:
ifeq ($(DEB_BUILD_GNU_TYPE),$(DEB_HOST_GNU_TYPE)) DEB_MAKE_CHECK_TARGET = check endif
The endif doesn't belong to the end of debian/rules. It should only cover DEB_MAKE_ CHECK_TARGET:
ifeq ($(DEB_ BUILD_GNU_ TYPE),$ (DEB_HOST_ GNU_TYPE) ) CHECK_TARGET = check
DEB_MAKE_
endif