diff options
author | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-24 01:08:49 +0000 |
---|---|---|
committer | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-24 01:08:49 +0000 |
commit | 84ca3e3f38602c5cca8ef6c906200912f21cae7c (patch) | |
tree | 09ca28dfda5f80bdd8d7ce0f7d49f187f5ddf11f /tools/clang | |
parent | b4a5627951869138f61d90908027a4b5a71d638b (diff) | |
download | chromium_src-84ca3e3f38602c5cca8ef6c906200912f21cae7c.zip chromium_src-84ca3e3f38602c5cca8ef6c906200912f21cae7c.tar.gz chromium_src-84ca3e3f38602c5cca8ef6c906200912f21cae7c.tar.bz2 |
Revert 102596 (which has no -s on linux apparently) - clang updater: Prefer curl over wget on linux if installed.
BUG=97288
TEST=none
Review URL: http://codereview.chromium.org/8015020
TBR=thakis@chromium.org
Review URL: http://codereview.chromium.org/8028013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@102631 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools/clang')
-rwxr-xr-x | tools/clang/scripts/update.sh | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/tools/clang/scripts/update.sh b/tools/clang/scripts/update.sh index 9fb292a..aaa01b7 100755 --- a/tools/clang/scripts/update.sh +++ b/tools/clang/scripts/update.sh @@ -118,20 +118,13 @@ if [ -z "$force_local_build" ]; then CDS_FILE="clang-${CLANG_REVISION}.tgz" CDS_OUT_DIR=$(mktemp -d -t clang_download.XXXXXX) CDS_OUTPUT="${CDS_OUT_DIR}/${CDS_FILE}" + echo Trying to download prebuilt clang if [ "${OS}" = "Linux" ]; then - CDS_FULL_URL="${CDS_URL}/Linux_x64/${CDS_FILE}" + wget "${CDS_URL}/Linux_x64/${CDS_FILE}" -O "${CDS_OUTPUT}" || \ + rm -rf "${CDS_OUT_DIR}" elif [ "${OS}" = "Darwin" ]; then - CDS_FULL_URL="${CDS_URL}/Mac/${CDS_FILE}" - fi - echo Trying to download prebuilt clang - if which -s curl; then - curl -L --fail "${CDS_FULL_URL}" -o "${CDS_OUTPUT}" || \ + curl -L --fail "${CDS_URL}/Mac/${CDS_FILE}" -o "${CDS_OUTPUT}" || \ rm -rf "${CDS_OUT_DIR}" - elif which -s wget; then - wget "${CDS_FULL_URL}" -O "${CDS_OUTPUT}" || rm -rf "${CDS_OUT_DIR}" - else - echo "Neither curl nor wget found. Please install one of these." - exit 1 fi if [ -f "${CDS_OUTPUT}" ]; then rm -rf "${LLVM_BUILD_DIR}/Release+Asserts" |