Source: icu Version: 52.1-7 Tags: patch User: helm...@debian.org Usertags: rebootstrap
The current icu package cannot be cross compiled, because icu needs two build passes for cross compiling: a build arch pass and a host arch pass. The procedure is documented in the upstream readme[1], but not yet implemented in the Debian package. Please consider applying the attached patch. It uses cdbs' support for build flavours to build a "hostarch" flavour by default. That means changing the location of the native build. When encountering a cross build it adds a "buildarch" flavour and passes that as --with-cross-build to the "hostarch" flavour implementing upstream's guidelines. I hope that the changes to the native build are acceptable. Don't hesitate to ask, if you have questions concerning the patch. Helmut [1] http://source.icu-project.org/repos/icu/icu/trunk/readme.html#HowToCrossCompileICU
diff -Nru icu-52.1/debian/changelog icu-52.1/debian/changelog --- icu-52.1/debian/changelog +++ icu-52.1/debian/changelog @@ -1,3 +1,10 @@ +icu (52.1-7.1) UNRELEASED; urgency=low + + * Non-maintainer upload. + * Support cross compilation. (Closes: #-1) + + -- Helmut Grohne <hel...@subdivi.de> Sun, 01 Feb 2015 14:45:57 +0100 + icu (52.1-7) unstable; urgency=high * Patch to CVE-2014-6591, CVE-2014-6585 a font parsing bug. diff -Nru icu-52.1/debian/rules icu-52.1/debian/rules --- icu-52.1/debian/rules +++ icu-52.1/debian/rules @@ -26,6 +26,23 @@ CXXFLAGS := $(filter-out -O%,$(CXXFLAGS)) -O0 endif +DEB_BUILDDIR = build +DEB_MAKE_FLAVORS = hostarch +ifneq ($(DEB_HOST_ARCH),$(DEB_BUILD_ARCH)) +DEB_MAKE_FLAVORS += buildarch +DEB_CONFIGURE_FLAGS_buildarch = --host=$(DEB_BUILD_GNU_TYPE) +DEB_CONFIGURE_FLAGS_hostarch = --with-cross-build=$(CURDIR)/build/buildarch +debian/stamp-autotools/buildarch: DEB_CONFIGURE_CROSSBUILD_ARGS= +# do not force a cross compiler for the native build +debian/stamp-makefile-build/buildarch: DEB_MAKE_ENVVARS= +# do not install the buildarch flavor +debian/stamp-makefile-install/buildarch: DEB_MAKE_INSTALL_TARGET= +debian/stamp-autotools/hostarch: debian/stamp-makefile-build/buildarch + mkdir -p build/hostarch + $(DEB_CONFIGURE_INVOKE) $(cdbs_configure_flags) $(DEB_CONFIGURE_EXTRA_FLAGS) $(DEB_CONFIGURE_USER_FLAGS) + touch $@ +endif + # Include cdbs rules files. include /usr/share/cdbs/1/rules/debhelper.mk include /usr/share/cdbs/1/class/autotools.mk @@ -44,6 +61,7 @@ clean:: $(RM) *.cdbs-config_list + $(RM) -R build # The libicudata library contains no symbols, so its debug library is # useless and triggers lintian warnings. Just remove it.