# HG changeset patch # User Alain Leufroy # Date 1295267778 -3600 # Node ID fb3633142d8fd340efe524803cc350f79257c886 # Parent 87e2641d75f7e76adc9690bb54074862f95a223a [pkg] fix small bug appearing on Windows diff -r 87e2641d75f7 -r fb3633142d8f setup.py --- a/setup.py Mon Jan 17 12:43:07 2011 +0100 +++ b/setup.py Mon Jan 17 13:36:18 2011 +0100 @@ -194,9 +194,10 @@ old_ok = DS._ok def _ok(self, path): """Return True if ``path`` can be written during installation.""" - out = old_ok(self, path) + out = old_ok(self, path) # here for side effect from setuptools realpath = os.path.normcase(os.path.realpath(path)) - if realpath.startswith(sys.prefix): + allowed_path = os.path.normcase(sys.prefix) + if realpath.startswith(allowed_path): out = True return out DS._ok = _ok