aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/package
diff options
context:
space:
mode:
authorFathi Boudra <fathi.boudra@linaro.org>2014-04-12 06:13:24 -0400
committerMichal Marek <mmarek@suse.cz>2014-04-24 09:25:09 -0400
commit6b4a144a92ab81a1f45fb9b12aebaaaee0d08120 (patch)
tree73865a703ac95e4e04cfff436aa375381a9d9e8a /scripts/package
parent8c38a5328af8080bc69a25b3e4e144b03eeea95e (diff)
builddeb: use $OBJCOPY variable instead of objcopy
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> Cc: stable <stable@vger.kernel.org> # 3.12+ 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>
Diffstat (limited to 'scripts/package')
-rw-r--r--scripts/package/builddeb6
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
155 for module in $(find lib/modules/ -name *.ko); do 155 for module in $(find lib/modules/ -name *.ko); do
156 mkdir -p $(dirname $dbg_dir/usr/lib/debug/$module) 156 mkdir -p $(dirname $dbg_dir/usr/lib/debug/$module)
157 # only keep debug symbols in the debug file 157 # only keep debug symbols in the debug file
158 objcopy --only-keep-debug $module $dbg_dir/usr/lib/debug/$module 158 $OBJCOPY --only-keep-debug $module $dbg_dir/usr/lib/debug/$module
159 # strip original module from debug symbols 159 # strip original module from debug symbols
160 objcopy --strip-debug $module 160 $OBJCOPY --strip-debug $module
161 # then add a link to those 161 # then add a link to those
162 objcopy --add-gnu-debuglink=$dbg_dir/usr/lib/debug/$module $module 162 $OBJCOPY --add-gnu-debuglink=$dbg_dir/usr/lib/debug/$module $module
163 done 163 done
164 ) 164 )
165 fi 165 fi