Support Debian cross-building

Respect DEB_HOST_GNU_TYPE when selecting CC for cross-compiling.
Fixes Debian bug #695442 reported by Adam Conrad.
This commit is contained in:
Marco d'Itri 2013-03-31 21:43:19 +02:00
parent e5e1efe2c3
commit 130cfbf215

7
debian/rules vendored
View File

@ -1,6 +1,13 @@
#!/usr/bin/make -f
SHELL+= -e
DEB_HOST_GNU_TYPE := $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
DEB_BUILD_GNU_TYPE := $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
ifneq ($(DEB_HOST_GNU_TYPE),$(DEB_BUILD_GNU_TYPE))
export CC := $(DEB_HOST_GNU_TYPE)-$(CC)
endif
DPKG_EXPORT_BUILDFLAGS = 1
-include /usr/share/dpkg/buildflags.mk