]> git.apps.os.sepia.ceph.com Git - ceph-build.git/commitdiff
scripts: upgrade pip with easy_install before actual pinning 1011/head
authorAlfredo Deza <adeza@redhat.com>
Tue, 17 Apr 2018 16:08:06 +0000 (12:08 -0400)
committerAlfredo Deza <adeza@redhat.com>
Tue, 17 Apr 2018 16:08:06 +0000 (12:08 -0400)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
scripts/build_utils.sh

index 0511158286e1793ec289a9707a594b8b0a91c888..b9a3aaff8556595cb9e5b8fa8e9c546ee656d0e2 100644 (file)
@@ -61,7 +61,11 @@ install_python_packages_no_binary () {
     echo "Ensuring latest pip is installed"
     # XXX This means we are now pinning to 10.0.0, to prevent issues on pip
     # mismtaching versions, but also that we need to revisit this when newer
-    # options are needed
+    # options are needed. ``easy_install`` is a must on systems with ancient
+    # versions of pip that break with newer versions of pkg_resources that come
+    # with the virtualenv. Doing an initial upgrade with easy_install
+    # circumvents the problem
+    $VENV/easy_install --upgrade pip
     $VENV/pip install "pip==10.0.0"
     $VENV/pip install --upgrade --exists-action=i --find-links="file://$PIP_SDIST_INDEX" --no-index pip
 
@@ -98,7 +102,11 @@ install_python_packages () {
     echo "Ensuring latest pip is installed"
     # XXX This means we are now pinning to 10.0.0, to prevent issues on pip
     # mismtaching versions, but also that we need to revisit this when newer
-    # options are needed
+    # options are needed. ``easy_install`` is a must on systems with ancient
+    # versions of pip that break with newer versions of pkg_resources that come
+    # with the virtualenv. Doing an initial upgrade with easy_install
+    # circumvents the problem
+    $VENV/easy_install --upgrade pip
     $VENV/pip install "pip==10.0.0"
     $VENV/pip install --upgrade --exists-action=i --find-links="file://$PIP_SDIST_INDEX" --no-index pip