[Bug 962997] Re: FTCBFS: Cross build calls wrong-arch strip

Wookey wookey at wookware.org
Tue Mar 27 13:26:13 UTC 2012


I don't actually understand why this works. I fixed it slightly
differently by explicitly setting $STRIP.

If just setting $CROSS is enough to fix this, how many other things can
be fixed by setting $CROSS? What exactly is the scope of this - does it
only work in binutils or does it have wider application? I tried reading
the autconf manula and it didn't seem to say anything about this. How is
setting $CROSS different from setting --host?

Is there any reason to prefer one of these fixes over the other?
Marcin's is shorter, mine is a bit clearer?

Is cross-auto-foo best practice actually written down anywhere?

diff -ur origs/debianutils-4.2.2/debian/rules patched/debianutils-4.2.2/debian/rules
--- origs/debianutils-4.2.2/debian/rules        2012-03-24 14:52:38.000000000 +0000
+++ patched/debianutils-4.2.2/debian/rules      2012-03-27 11:46:21.000000000 +0000
@@ -12,8 +12,12 @@
 DEB_BUILD_ARCH_OS ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH_OS)
 DEB_BUILD_GNU_TYPE = $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
 DEB_HOST_GNU_TYPE = $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+
+STRIP=strip
+
 ifneq ($(DEB_BUILD_GNU_TYPE),$(DEB_HOST_GNU_TYPE))
 CONFARGS = --host=$(DEB_HOST_GNU_TYPE)
+STRIP=$(DEB_HOST_GNU_TYPE)-strip
 endif

 CFLAGS := $(shell dpkg-buildflags --get CFLAGS)
@@ -63,7 +67,7 @@
           debian/tmp/bin/

 ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
-       strip --remove-section=.comment --remove-section=.note \
+       $(STRIP) --remove-section=.comment --remove-section=.note \
                debian/tmp/bin/run-parts \
                debian/tmp/bin/tempfile \
                debian/tmp/usr/bin/ischroot

-- 
You received this bug notification because you are a member of Ubuntu
Sponsors Team, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/962997

Title:
  FTCBFS: Cross build calls wrong-arch strip

Status in “debianutils” package in Ubuntu:
  Fix Committed

Bug description:
  Debianutils does not call the correct arch strip so cross-builds fail
  right at the end.

  See build log at: http://people.linaro.org/~wookey/buildd/precise
  /sbuild-ma/debianutils_4.2.1ubuntu1-precise-ma-cross-
  armel-20120322-023654.34137.log

  The attached patch fixes that.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/debianutils/+bug/962997/+subscriptions



More information about the Ubuntu-sponsors mailing list