diff options
author | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-09-22 02:00:47 +0000 |
---|---|---|
committer | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-09-22 02:00:47 +0000 |
commit | eb49842c7d97917b00e1edfbf99bdeab78ea9f7f (patch) | |
tree | b8f042ea9da1749eec0debd126211471614a6a45 /tools | |
parent | 4c00704f744e1d2ca1be9b7f67501a46452d4e03 (diff) | |
download | chromium_src-eb49842c7d97917b00e1edfbf99bdeab78ea9f7f.zip chromium_src-eb49842c7d97917b00e1edfbf99bdeab78ea9f7f.tar.gz chromium_src-eb49842c7d97917b00e1edfbf99bdeab78ea9f7f.tar.bz2 |
Fixes for building and running valgrind on Ubuntu
- valgrind.sh is a bash script
- Look for ld.single as well as ld.orig when searching for !gold ld
Patch by Joel Stanley <joel@jms.id.au>
Review URL: http://codereview.chromium.org/209009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26785 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/valgrind/build-valgrind-for-chromium.sh | 8 | ||||
-rwxr-xr-x | tools/valgrind/valgrind.sh | 2 |
2 files changed, 9 insertions, 1 deletions
diff --git a/tools/valgrind/build-valgrind-for-chromium.sh b/tools/valgrind/build-valgrind-for-chromium.sh index f11e43c..726cd10 100755 --- a/tools/valgrind/build-valgrind-for-chromium.sh +++ b/tools/valgrind/build-valgrind-for-chromium.sh @@ -124,6 +124,14 @@ then mkdir "${OVERRIDE_LD_DIR}" ln -s /usr/bin/ld.orig "${OVERRIDE_LD_DIR}/ld" PATH="${OVERRIDE_LD_DIR}:${PATH}" + # Ubuntu diverts original ld to ld.single when it installs binutils-gold + elif test -x /usr/bin/ld.single + then + echo "Using /usr/bin/ld.single instead of gold to link valgrind" + test -d "${OVERRIDE_LD_DIR}" && rm -rf "${OVERRIDE_LD_DIR}" + mkdir "${OVERRIDE_LD_DIR}" + ln -s /usr/bin/ld.single "${OVERRIDE_LD_DIR}/ld" + PATH="${OVERRIDE_LD_DIR}:${PATH}" else echo "Cannot build valgrind with gold. Please switch to normal /usr/bin/ld, rerun this script, then switch back to gold." exit 1 diff --git a/tools/valgrind/valgrind.sh b/tools/valgrind/valgrind.sh index 5db5bfd..3f4c07e 100755 --- a/tools/valgrind/valgrind.sh +++ b/tools/valgrind/valgrind.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # Copyright (c) 2009 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be |