diff options
author | dkegel@google.com <dkegel@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-01-08 14:54:45 +0000 |
---|---|---|
committer | dkegel@google.com <dkegel@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-01-08 14:54:45 +0000 |
commit | 6f4f66fab5503a2503a57ab2424297d24b6018a5 (patch) | |
tree | 6676d8c3432336b24f907de1a9b6e2a0a082069b /build/install-build-deps.sh | |
parent | c7256dc969aeac5163c444b89e14634f5d538823 (diff) | |
download | chromium_src-6f4f66fab5503a2503a57ab2424297d24b6018a5.zip chromium_src-6f4f66fab5503a2503a57ab2424297d24b6018a5.tar.gz chromium_src-6f4f66fab5503a2503a57ab2424297d24b6018a5.tar.bz2 |
Download into unique subdir of /tmp to avoid permission problems (e.g. root not allowed to access nfs).
Clean up carefully afterwards.
Review URL: http://codereview.chromium.org/17415
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7728 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build/install-build-deps.sh')
-rwxr-xr-x | build/install-build-deps.sh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/build/install-build-deps.sh b/build/install-build-deps.sh index b721604..673e8c8 100755 --- a/build/install-build-deps.sh +++ b/build/install-build-deps.sh @@ -4,6 +4,16 @@ # and http://code.google.com/p/chromium/wiki/LinuxBuild64Bit set -ex +# Root can't access files on all filesystems, but /tmp should always be ok +# (unless it's full). +DIR=`mktemp -d` +cd $DIR +touch .created + +cleanup() { + test -f $DIR/.created && rm -rf $DIR +} + # TODO(dkegel): add sha1sum verification download() { dir=$1 @@ -95,6 +105,8 @@ then install_hardy_64 else echo "Unsupported system" + cleanup exit 1 fi +cleanup |