From 66687c908c8dcc564bd210302efa8508995f6c92 Mon Sep 17 00:00:00 2001
From: Andre Anjos <andre.dos.anjos@gmail.com>
Date: Sat, 24 Sep 2016 08:56:01 +0200
Subject: [PATCH] Don't change venv (doesn't work on macosx)

---
 gitlab/before_test.sh |  4 ++--
 gitlab/build.sh       | 13 ++++---------
 gitlab/functions.sh   |  2 +-
 gitlab/test.sh        |  6 +++---
 4 files changed, 10 insertions(+), 15 deletions(-)

diff --git a/gitlab/before_test.sh b/gitlab/before_test.sh
index 3709c10..bd8e081 100755
--- a/gitlab/before_test.sh
+++ b/gitlab/before_test.sh
@@ -20,7 +20,7 @@ fi
 
 # zc.recipe.egg needs some special installation instructions
 if [ "${CI_PROJECT_NAME}" == "bob.buildout" ]; then
-  run_cmd ${use_pip} install --upgrade --no-binary ":all:" zc.recipe.egg
+  run_cmd_ld ${use_pip} install --upgrade --no-binary ":all:" zc.recipe.egg
 fi
 
-run_cmd ${use_pip} install --upgrade --use-wheel --no-index --pre dist/*.whl
+run_cmd_ld ${use_pip} install --upgrade --use-wheel --no-index --pre dist/*.whl
diff --git a/gitlab/build.sh b/gitlab/build.sh
index 28833cd..f59b27d 100755
--- a/gitlab/build.sh
+++ b/gitlab/build.sh
@@ -5,23 +5,18 @@ source $(dirname ${0})/functions.sh
 
 run_cmd_ld ./bin/buildout
 
-# Corrects the virtualenv to take LD_LIBRARY_PATH into account
-if [ ${ARCH} == "linux" ]; then
-  fix_venv
-fi
-
 if [ -x ./bin/bob_dbmanage.py ]; then
-  run_cmd ./bin/bob_dbmanage.py all download --force;
+  run_cmd_ld ./bin/bob_dbmanage.py all download --force;
 fi
 
 if [ -d ./doc ]; then
-  run_cmd ./bin/sphinx-build doc sphinx
+  run_cmd_ld ./bin/sphinx-build doc sphinx
 fi
 
 if [ -z "${WHEEL_TAG}" ]; then
   # C/C++ extensions
-  run_cmd ./bin/python setup.py bdist_wheel
+  run_cmd_ld ./bin/python setup.py bdist_wheel
 else
   # Python-only packages
-  run_cmd ./bin/python setup.py bdist_wheel --python-tag ${WHEEL_TAG}
+  run_cmd_ld ./bin/python setup.py bdist_wheel --python-tag ${WHEEL_TAG}
 fi
diff --git a/gitlab/functions.sh b/gitlab/functions.sh
index 8cc6b8c..eec9fb9 100644
--- a/gitlab/functions.sh
+++ b/gitlab/functions.sh
@@ -73,7 +73,7 @@ run_cmd_ld() {
 
 # Runs setup.py
 setup() {
-  run_cmd ${PREFIX}/bin/python setup.py ${@}
+  run_cmd_ld ${PREFIX}/bin/python setup.py ${@}
 }
 
 
diff --git a/gitlab/test.sh b/gitlab/test.sh
index 85ac251..434de6c 100755
--- a/gitlab/test.sh
+++ b/gitlab/test.sh
@@ -6,8 +6,8 @@ source $(dirname ${0})/functions.sh
 run_cmd cd ${PREFIX}
 
 # The tests:
-run_cmd ${PREFIX}/bin/python ${BOB_PREFIX_PATH}/bin/coverage run --source=${CI_PROJECT_NAME} ${BOB_PREFIX_PATH}/bin/nosetests -sv ${CI_PROJECT_NAME}
-run_cmd ${PREFIX}/bin/python ${BOB_PREFIX_PATH}/bin/coverage report
-run_cmd ${PREFIX}/bin/python ${BOB_PREFIX_PATH}/bin/sphinx-build -b doctest ${CI_PROJECT_DIR}/doc ${CI_PROJECT_NAME}/sphinx
+run_cmd_ld ${PREFIX}/bin/python ${BOB_PREFIX_PATH}/bin/coverage run --source=${CI_PROJECT_NAME} ${BOB_PREFIX_PATH}/bin/nosetests -sv ${CI_PROJECT_NAME}
+run_cmd_ld ${PREFIX}/bin/python ${BOB_PREFIX_PATH}/bin/coverage report
+run_cmd_ld ${PREFIX}/bin/python ${BOB_PREFIX_PATH}/bin/sphinx-build -b doctest ${CI_PROJECT_DIR}/doc ${CI_PROJECT_NAME}/sphinx
 
 run_cmd cd ${CI_PROJECT_DIR}
-- 
GitLab