[snapshot/master] Do not hardcode version number in sys.path if we have distutils
---
fsck/check-1/hash | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/fsck/check-1/hash b/fsck/check-1/hash
index 48a9be5..4304de1 100755
--- a/fsck/check-1/hash
+++ b/fsck/check-1/hash
@@ -28,7 +28,11 @@ import sys
import threading
import random
import Queue
-sys.path.append(os.path.abspath(os.path.dirname(sys.argv[0]))+'/lib/python2.6/site-packages')
+try:
+ from distutils import sysconfig
+ sys.path.append(sysconfig.get_python_lib(prefix=os.path.abspath(os.path.dirname(sys.argv[0]))))
+except ImportError:
+ sys.path.append(os.path.abspath(os.path.dirname(sys.argv[0]))+'/lib/python2.6/site-packages')
import hasher
--
1.7.2.5
Reply to: