setup.py: only use real paths

This commit is contained in:
R. Andrew Ohana 2013-12-11 01:13:06 -08:00
parent 3f3a7b1b06
commit d999a8b170

View File

@ -37,7 +37,10 @@ _LIB_IMAGING = (
def _add_directory(path, dir, where=None):
if dir and os.path.isdir(dir) and dir not in path:
if dir is None:
return
dir = os.path.realpath(dir)
if os.path.isdir(dir) and dir not in path:
if where is None:
path.append(dir)
else: