From patchwork Wed Sep 19 08:56:18 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: scripts: Select the correct "strip" to strip gdbserver for Canadian build Date: Tue, 18 Sep 2012 22:56:18 -0000 From: Zhenqiang Chen X-Patchwork-Id: 184951 Message-Id: To: Mike Frysinger Cc: crossgcc@sourceware.org, "Yann E. MORIN" > could you set a local variable so that you don't have to copy & paste the > entire command twice ? > local cross_strip="bin/${CT_TARGET}-strip" > [[ ${CT_TARGET} == "y" ]] && cross_strip=${CT_TARGET}-strip > CT_DoExecLog ALL ${cross_strip} ... Thanks for the comments. Update it as: exporting patch: # HG changeset patch # User Zhenqiang Chen # Date 1348044842 -28800 # Node ID 49dc965c5eada0b4bbef5f7810a259eae5773bb1 # Parent 2858a24a584642e263a920b4214c815c172ed547 scripts: Select the correct "strip" to strip gdbserver for Canadian build. For Canadian build, we can not run the bin/${CT_TARGET}-strip on the build system. But ${CT_TARGET}-strip should be on PATH. Signed-off-by: Zhenqiang Chen --- For unsubscribe information see http://sourceware.org/lists.html#faq diff -r 2858a24a5846 -r 49dc965c5ead scripts/build/internals.sh --- a/scripts/build/internals.sh Sun Aug 12 07:45:42 2012 -0400 +++ b/scripts/build/internals.sh Wed Sep 19 16:54:02 2012 +0800 @@ -25,8 +25,12 @@ # Strip gdbserver if [ "${CT_GDB_GDBSERVER}" = "y" ]; then - CT_DoExecLog ALL bin/${CT_TARGET}-strip ${strip_args} \ - ${CT_TARGET}/debug-root/usr/bin/gdbserver + local cross_strip="bin/${CT_TARGET}-strip" + # For Canadian build, we can not run the bin/${CT_TARGET}-strip on + # the build system. But ${CT_TARGET}-strip should be on PATH. + [ "${CT_CANADIAN}" = "y" ] && cross_strip="${CT_TARGET}-strip" + CT_DoExecLog ALL ${cross_strip} ${strip_args} \ + ${CT_TARGET}/debug-root/usr/bin/gdbserver fi # We can not use the version in CT_CC_VERSION because # of the Linaro stuff. So, harvest the version string