Package: cpio Version: 2.11-7 Followup-For: Bug #627444 User: ubuntu-de...@lists.ubuntu.com Usertags: origin-ubuntu precise ubuntu-patch
Hi there, Here is an additional fix that's useful for cross-building. Currently the 'strip' command included in binutils (i.e., provided by build-essential) only understands executables of the build architecture. I presume that when Steve did his cross-build test with cpio, he had binutils-multiarch installed, which provides a 'strip' command that supports all known object formats. Since binutils-multiarch is redundant when you already have a cross-toolchain installed on the system, and since it's not actually guaranteed that the binutils-multiarch in the archive understands the object format of the architecture you're cross-compiling for, it's better to simply use the strip that's provided by the cross-binutils. The attached patch implements this. Please consider applying it along with the previous patch from Steve. For reference, both patches have been applied to cpio in Ubuntu. Cheers, -- Steve Langasek Give me a lever long enough and a Free OS Debian Developer to set it on, and I can move the world. Ubuntu Developer http://www.debian.org/ slanga...@ubuntu.com vor...@debian.org
=== modified file 'debian/rules' --- debian/rules 2011-01-18 12:22:07 +0000 +++ debian/rules 2012-04-01 18:06:49 +0000 @@ -13,8 +13,10 @@ DEB_BUILD_GNU_TYPE=$(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) ifneq ($(DEB_HOST_GNU_TYPE),$(DEB_BUILD_GNU_TYPE)) CROSS= --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE) +STRIP = $(DEB_HOST_GNU_TYPE)-strip else CROSS= --build $(DEB_BUILD_GNU_TYPE) +STRIP = strip endif ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) @@ -114,7 +116,7 @@ debian/tmp/usr/share/man/man1/mt-gnu.1 # Strip binaries (including hack by policy wonks) ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) - strip -R.note -R.comment debian/tmp/bin/* + $(STRIP) -R.note -R.comment debian/tmp/bin/* endif rm -rf debian/tmp/usr/sbin # Install documentation
signature.asc
Description: Digital signature