aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'bin/egencache')
-rwxr-xr-xbin/egencache11
1 files changed, 4 insertions, 7 deletions
diff --git a/bin/egencache b/bin/egencache
index d0c073c6e..a0766b1f2 100755
--- a/bin/egencache
+++ b/bin/egencache
@@ -28,13 +28,10 @@ import time
import textwrap
import re
-try:
- import portage
-except ImportError:
- from os import path as osp
- sys.path.insert(0, osp.join(osp.dirname(osp.dirname(osp.realpath(__file__))), "pym"))
- import portage
-
+from os import path as osp
+pym_path = osp.join(osp.dirname(osp.dirname(osp.realpath(__file__))), "pym")
+sys.path.insert(0, pym_path)
+import portage
from portage import os, _encodings, _unicode_encode, _unicode_decode
from _emerge.MetadataRegen import MetadataRegen
from portage.cache.cache_errors import CacheError, StatCollision