summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-admin/python-updater/files/python-updater-0.7-fix_import.patch')
-rw-r--r--app-admin/python-updater/files/python-updater-0.7-fix_import.patch49
1 files changed, 49 insertions, 0 deletions
diff --git a/app-admin/python-updater/files/python-updater-0.7-fix_import.patch b/app-admin/python-updater/files/python-updater-0.7-fix_import.patch
new file mode 100644
index 000000000000..bf46ce4cae8f
--- /dev/null
+++ b/app-admin/python-updater/files/python-updater-0.7-fix_import.patch
@@ -0,0 +1,49 @@
+--- python-updater
++++ python-updater
+@@ -34,7 +34,6 @@
+ VERBOSE=0
+ PKGS_TO_REMERGE=""
+ PKGS_COUNT_REMERGE=0
+-PORTAGE_PYTHON="/usr/bin/python"
+ PYTHON_VERSIONS="3.2 3.1 3.0 2.7 2.6 2.5 2.4 2.3 2.2 2.1"
+
+ SUPPORTED_PMS="portage pkgcore paludis"
+@@ -132,26 +131,6 @@
+ return 1
+ }
+
+-# get_portage_python(oldpy,newpy)
+-# Find where portage is, in pythonX.Y or somewhere else?
+-get_portage_python() {
+- if [[ $# -lt 2 ]]; then
+- eerror "get_portage_python(): Missing arguments."
+- exit 1
+- fi
+- local oldpy="$1" newpy="$2"
+-
+- pybin=/usr/bin/python
+- for py in ${pybin} ${pybin}${oldpy} ${pybin}${newpy}; do
+- if ${py} -c "import portage" > /dev/null 2>&1; then
+- echo -n "${py}"
+- return 0
+- fi
+- done
+- eerror "Couldn't determine portage python"
+- return 1
+-}
+-
+ # get_portage_portdir()
+ # Check if portage knows about PORTDIR and return it
+ get_portage_portdir() {
+@@ -294,11 +273,6 @@
+ fi
+ fi
+
+-# Get portage python
+-PORTAGE_PYTHON="$(get_portage_python ${OLD_PY_VER} ${NEW_PY_VER})"
+-[[ $? != 0 ]] && exit 1
+-
+-
+ einfo "Starting Python Updater from ${OLD_PY_VER} to ${NEW_PY_VER} :"
+ if [[ CHECK_SONAME -ne 0 ]]; then
+ if ! type -P scanelf >/dev/null 2>&1; then