Browse code

Drop workaround for pip < 1.4

Now that we are on pip 1.5.6 lets drop the workaround to make pip 1.4
work. As this is a development/testing tool requiring a newer pip
shouldn't be an issue. Also stack.sh installs pip by default.

Work around introduced in https://github.com/pypa/pip/issues/709

Change-Id: I0e7aad1d21f4fce4c020ce36685bb56893c66bdc

Joe Gordon authored on 2014/10/02 10:21:08
Showing 3 changed files
... ...
@@ -21,17 +21,6 @@ function function_exists {
21 21
     declare -f -F $1 > /dev/null
22 22
 }
23 23
 
24
-
25
-# Cleanup anything from /tmp on unstack
26
-# clean_tmp
27
-function cleanup_tmp {
28
-    local tmp_dir=${TMPDIR:-/tmp}
29
-
30
-    # see comments in pip_install
31
-    sudo rm -rf ${tmp_dir}/pip-build.*
32
-}
33
-
34
-
35 24
 # Retrieve an image from a URL and upload into Glance.
36 25
 # Uses the following variables:
37 26
 #
... ...
@@ -1509,15 +1509,6 @@ function pip_install {
1509 1509
         pip_mirror_opt="--use-mirrors"
1510 1510
     fi
1511 1511
 
1512
-    # pip < 1.4 has a bug where it will use an already existing build
1513
-    # directory unconditionally.  Say an earlier component installs
1514
-    # foo v1.1; pip will have built foo's source in
1515
-    # /tmp/$USER-pip-build.  Even if a later component specifies foo <
1516
-    # 1.1, the existing extracted build will be used and cause
1517
-    # confusing errors.  By creating unique build directories we avoid
1518
-    # this problem. See https://github.com/pypa/pip/issues/709
1519
-    local pip_build_tmp=$(mktemp --tmpdir -d pip-build.XXXXX)
1520
-
1521 1512
     $xtrace
1522 1513
     $sudo_pip PIP_DOWNLOAD_CACHE=${PIP_DOWNLOAD_CACHE:-/var/cache/pip} \
1523 1514
         http_proxy=$http_proxy \
... ...
@@ -173,5 +173,3 @@ if [[ -n "$SCREEN" ]]; then
173 173
         screen -X -S $SESSION quit
174 174
     fi
175 175
 fi
176
-
177
-cleanup_tmp