diff options
author | brad kittenbrink <brad@lindenlab.com> | 2009-07-30 19:39:08 -0700 |
---|---|---|
committer | brad kittenbrink <brad@lindenlab.com> | 2009-07-30 19:39:08 -0700 |
commit | a7efd0d8ddb68315653265d7e4ab87a156e56560 (patch) | |
tree | 4210ae49796fdb8fb4b28f0bdd857dc338110070 /scripts | |
parent | b3a83059c464c9a974d547f57ab8e93ca0bee0f1 (diff) | |
parent | 29607ab70edea79cfdceaa52d632d77e6699cb8f (diff) |
Merged in viewer-2.0.0-3 changes up through r129050. Boost got clobbered so I'll need to rebuild that, plus a couple other minor clenaups.
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/install.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/scripts/install.py b/scripts/install.py index 6278fba16c..78b8880b95 100755 --- a/scripts/install.py +++ b/scripts/install.py @@ -64,7 +64,6 @@ def add_indra_lib_path(): base_dir = add_indra_lib_path() import copy -import md5 import optparse import os import platform @@ -75,7 +74,12 @@ import tempfile import urllib2 import urlparse -from sets import Set as set, ImmutableSet as frozenset +try: + # Python 2.6 + from hashlib import md5 +except ImportError: + # Python 2.5 and earlier + from md5 import new as md5 from indra.base import llsd from indra.util import helpformatter @@ -106,7 +110,7 @@ class InstallFile(object): return "ifile{%s:%s}" % (self.pkgname, self.url) def _is_md5sum_match(self): - hasher = md5.new(file(self.filename, 'rb').read()) + hasher = md5(file(self.filename, 'rb').read()) if hasher.hexdigest() == self.md5sum: return True return False |