diff options
author | Fathi Boudra <fathi.boudra@linaro.org> | 2014-04-12 13:13:24 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-06-30 20:14:04 -0700 |
commit | 7f922b1920f7c38a6cf0645aea543b0ec343eb0f (patch) | |
tree | 4d900324b87cc430bf52a11f6f5d419b4669cfe3 | |
parent | 02bbff7274ac3f4a08536874a316e055d3be3ff5 (diff) | |
download | lwn-7f922b1920f7c38a6cf0645aea543b0ec343eb0f.tar.gz lwn-7f922b1920f7c38a6cf0645aea543b0ec343eb0f.zip |
builddeb: use $OBJCOPY variable instead of objcopy
commit 6b4a144a92ab81a1f45fb9b12aebaaaee0d08120 upstream.
In cross-build environment, we expect to use the cross-compiler objcopy
instead of the host objcopy.
It fixes following build failures:
objcopy --only-keep-debug lib/modules/3.14/kernel/net/ipv6/xfrm6_mode_tunnel.ko /srv/build/linux/debian/dbgtmp/usr/lib/debug/lib/modules/3.14/kernel/net/ipv6/xfrm6_mode_tunnel.ko
objcopy: Unable to recognise the format of the input file `lib/modules/3.14/kernel/net/ipv6/xfrm6_mode_tunnel.ko'
Signed-off-by: Fathi Boudra <fathi.boudra@linaro.org>
Fixes: 810e843746b7 ('deb-pkg: split debug symbols in their own package')
Reviewed-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: Michal Marek <mmarek@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | scripts/package/builddeb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/package/builddeb b/scripts/package/builddeb index f46e4dd0558d..152d4d25ab7c 100644 --- a/scripts/package/builddeb +++ b/scripts/package/builddeb @@ -155,11 +155,11 @@ if grep -q '^CONFIG_MODULES=y' $KCONFIG_CONFIG ; then for module in $(find lib/modules/ -name *.ko); do mkdir -p $(dirname $dbg_dir/usr/lib/debug/$module) # only keep debug symbols in the debug file - objcopy --only-keep-debug $module $dbg_dir/usr/lib/debug/$module + $OBJCOPY --only-keep-debug $module $dbg_dir/usr/lib/debug/$module # strip original module from debug symbols - objcopy --strip-debug $module + $OBJCOPY --strip-debug $module # then add a link to those - objcopy --add-gnu-debuglink=$dbg_dir/usr/lib/debug/$module $module + $OBJCOPY --add-gnu-debuglink=$dbg_dir/usr/lib/debug/$module $module done ) fi |