Use the host compiler for build tool c-ify.
[darkstat-debian] / debian / rules
index 514a26e..e63e77a 100755 (executable)
@@ -8,12 +8,14 @@ DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
 
 DPKG_EXPORT_BUILDFLAGS = 1
 include /usr/share/dpkg/buildflags.mk
+-include /usr/share/dpkg/buildtools.mk
+CC_FOR_BUILD ?= cc
 
 configure: configure-stamp
 configure-stamp: 
        dh_testdir
        cp /usr/share/misc/config.sub /usr/share/misc/config.guess .
-       CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man
+       CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --disable-silent-rules
        touch $@
 
 build: configure-stamp build-stamp
@@ -22,7 +24,7 @@ build-indep: build
 
 build-stamp: configure-stamp
        dh_testdir
-       $(MAKE)
+       $(MAKE) HOSTCC=$(CC_FOR_BUILD)
        touch $@
 
 clean: