From a97d1cc4a60bf137ec445b87f90ed9a8bff5ed5f Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Fri, 18 May 2007 22:37:45 +0000 Subject: Fall back to pickle if cPickle is unavailable. Thanks to Michael Haubenwallner for reporting. svn path=/main/trunk/; revision=6552 --- pym/portage/dbapi/vartree.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py index e9f2cf538..d438cbee0 100644 --- a/pym/portage/dbapi/vartree.py +++ b/pym/portage/dbapi/vartree.py @@ -20,9 +20,13 @@ from portage import listdir, dep_expand, config, flatten, key_expand, \ doebuild_environment, doebuild, env_update, dircache, \ abssymlink, movefile, bsd_chflags -import os, sys, stat, cPickle, errno, commands, copy, time +import os, sys, stat, errno, commands, copy, time from itertools import izip +try: + import cPickle +except ImportError: + import pickle as cPickle class PreservedLibsRegistry(object): """ This class handles the tracking of preserved library objects """ -- cgit v1.2.3-1-g7c22