[Lunar-commits] r21482 - moonbase/trunk/python/Python

Terry Chan tchan at lunar-linux.org
Thu Sep 21 17:43:31 UTC 2006


Author: tchan
Date: 2006-09-21 17:43:30 +0000 (Thu, 21 Sep 2006)
New Revision: 21482

Removed:
   moonbase/trunk/python/Python/PRE_BUILD
Modified:
   moonbase/trunk/python/Python/BUILD
   moonbase/trunk/python/Python/POST_INSTALL
Log:
Removing the non-working hack of checking on version numbers. Modified the perl
hack of updating modules to work with Python's site-packages.


Modified: moonbase/trunk/python/Python/BUILD
===================================================================
--- moonbase/trunk/python/Python/BUILD	2006-09-21 17:41:52 UTC (rev 21481)
+++ moonbase/trunk/python/Python/BUILD	2006-09-21 17:43:30 UTC (rev 21482)
@@ -1,10 +1,4 @@
 (
-  OLDV=$(installed_version $MODULE)
-
-  if [ ${OLDV:0:3} != ${MAJOR_VERSION} ] ; then
-        set_module_config OLD_VER "${OLDV:0:3}"
-  fi &&
-
   sedit "s:-O3:-O2:g" configure &&
 
   OPTS="$OPTS --enable-shared" &&

Modified: moonbase/trunk/python/Python/POST_INSTALL
===================================================================
--- moonbase/trunk/python/Python/POST_INSTALL	2006-09-21 17:41:52 UTC (rev 21481)
+++ moonbase/trunk/python/Python/POST_INSTALL	2006-09-21 17:43:30 UTC (rev 21482)
@@ -1,13 +1,11 @@
-OLD_VER="$(get_module_config OLD_VER)"
-NEWPYTHONDIR=/usr/lib/python$MAJOR_VERSION
-OLDPYTHONDIR=/usr/lib/python$OLD_VER
-
-if [ ! -z "$OLD_VER" ]; then
-  for ext in $OLDPYTHONDIR/site-packages/*; do
-    cp -a $ext $NEWPYTHONDIR/site-packages/;
-  done;
-  # Remove the old location
-  rm -rf $OLDPYTHONDIR
+#  Reinstall site-packages 
+message "$MESSAGE_COLOR"
+message "Any Python module previously installed is now broken due to the way"
+message "Python handles modules. They need to be recompiled in order to work."
+message "$DEFAULT_COLOR"
+if query "Do you want lunar to attempt to upgrade your Python modules?" y; then
+	PYTHONMODS="$( lvu from /usr/lib/python*/site-packages | cut -d: -f1 | uniq | grep -v Python)"
+	for PYTHONMOD in $(sort_by_dependency $PYTHONMODS); do
+		lin -c $PYTHONMOD || true
+	done
 fi
-
-unset_module_config OLD_VER

Deleted: moonbase/trunk/python/Python/PRE_BUILD



More information about the Lunar-commits mailing list