159dd616dSHerbert Dürr--- misc/Python-2.7.5/setup.py 2013-07-01 17:51:46.237674580 +0200 259dd616dSHerbert Dürr+++ misc/build/Python-2.7.5/setup.py 2013-07-01 17:51:24.230453108 +0200 359dd616dSHerbert Dürr@@ -80,61 +80,62 @@ 459dd616dSHerbert Dürr # system, but with only header files and libraries. 559dd616dSHerbert Dürr sysroot = macosx_sdk_root() 659dd616dSHerbert Dürr 759dd616dSHerbert Dürr- # Check the standard locations 859dd616dSHerbert Dürr- for dir in std_dirs: 959dd616dSHerbert Dürr+ # Check the additional directories 1059dd616dSHerbert Dürr+ for dir in paths: 1159dd616dSHerbert Dürr f = os.path.join(dir, filename) 1259dd616dSHerbert Dürr 1359dd616dSHerbert Dürr if host_platform == 'darwin' and is_macosx_sdk_path(dir): 1459dd616dSHerbert Dürr f = os.path.join(sysroot, dir[1:], filename) 1559dd616dSHerbert Dürr 1659dd616dSHerbert Dürr- if os.path.exists(f): return [] 1759dd616dSHerbert Dürr+ if os.path.exists(f): 1859dd616dSHerbert Dürr+ return [dir] 1959dd616dSHerbert Dürr 2059dd616dSHerbert Dürr- # Check the additional directories 2159dd616dSHerbert Dürr- for dir in paths: 2259dd616dSHerbert Dürr+ # Check the standard locations 2359dd616dSHerbert Dürr+ for dir in std_dirs: 2459dd616dSHerbert Dürr f = os.path.join(dir, filename) 2559dd616dSHerbert Dürr 2659dd616dSHerbert Dürr if host_platform == 'darwin' and is_macosx_sdk_path(dir): 2759dd616dSHerbert Dürr f = os.path.join(sysroot, dir[1:], filename) 2859dd616dSHerbert Dürr 2959dd616dSHerbert Dürr if os.path.exists(f): 3059dd616dSHerbert Dürr- return [dir] 3159dd616dSHerbert Dürr+ return [] 3259dd616dSHerbert Dürr 3359dd616dSHerbert Dürr # Not found anywhere 3459dd616dSHerbert Dürr return None 3559dd616dSHerbert Dürr 3659dd616dSHerbert Dürr def find_library_file(compiler, libname, std_dirs, paths): 3759dd616dSHerbert Dürr- result = compiler.find_library_file(std_dirs + paths, libname) 3859dd616dSHerbert Dürr+ result = compiler.find_library_file(paths+std_dirs, libname) 3959dd616dSHerbert Dürr if result is None: 4059dd616dSHerbert Dürr return None 4159dd616dSHerbert Dürr 4259dd616dSHerbert Dürr if host_platform == 'darwin': 4359dd616dSHerbert Dürr sysroot = macosx_sdk_root() 4459dd616dSHerbert Dürr 4559dd616dSHerbert Dürr- # Check whether the found file is in one of the standard directories 4659dd616dSHerbert Dürr dirname = os.path.dirname(result) 4759dd616dSHerbert Dürr- for p in std_dirs: 4859dd616dSHerbert Dürr+ # Otherwise, it must have been in one of the additional directories, 4959dd616dSHerbert Dürr+ # so we have to figure out which one. 5059dd616dSHerbert Dürr+ for p in paths: 5159dd616dSHerbert Dürr # Ensure path doesn't end with path separator 5259dd616dSHerbert Dürr p = p.rstrip(os.sep) 5359dd616dSHerbert Dürr 5459dd616dSHerbert Dürr if host_platform == 'darwin' and is_macosx_sdk_path(p): 5559dd616dSHerbert Dürr if os.path.join(sysroot, p[1:]) == dirname: 5659dd616dSHerbert Dürr- return [ ] 5759dd616dSHerbert Dürr+ return [ p ] 5859dd616dSHerbert Dürr 5959dd616dSHerbert Dürr if p == dirname: 6059dd616dSHerbert Dürr- return [ ] 6159dd616dSHerbert Dürr+ return [p] 6259dd616dSHerbert Dürr 6359dd616dSHerbert Dürr- # Otherwise, it must have been in one of the additional directories, 6459dd616dSHerbert Dürr- # so we have to figure out which one. 6559dd616dSHerbert Dürr- for p in paths: 6659dd616dSHerbert Dürr+ # Check whether the found file is in one of the standard directories 6759dd616dSHerbert Dürr+ for p in std_dirs: 6859dd616dSHerbert Dürr # Ensure path doesn't end with path separator 6959dd616dSHerbert Dürr p = p.rstrip(os.sep) 7059dd616dSHerbert Dürr 7159dd616dSHerbert Dürr if host_platform == 'darwin' and is_macosx_sdk_path(p): 7259dd616dSHerbert Dürr if os.path.join(sysroot, p[1:]) == dirname: 7359dd616dSHerbert Dürr- return [ p ] 7459dd616dSHerbert Dürr+ return [ ] 7559dd616dSHerbert Dürr 7659dd616dSHerbert Dürr if p == dirname: 7759dd616dSHerbert Dürr- return [p] 7859dd616dSHerbert Dürr+ return [ ] 7959dd616dSHerbert Dürr else: 8059dd616dSHerbert Dürr assert False, "Internal error: Path not found in std_dirs or paths" 8159dd616dSHerbert Dürr 82*d3c32b8cSHerbert Dürr@@ -819,6 +820,7 @@ 83*d3c32b8cSHerbert Dürr exts.append( Extension('_ssl', ['_ssl.c'], 84*d3c32b8cSHerbert Dürr include_dirs = ssl_incs, 85*d3c32b8cSHerbert Dürr library_dirs = ssl_libs, 86*d3c32b8cSHerbert Dürr+ extra_link_args = ['-Wl,--exclude-libs,ALL'], 87*d3c32b8cSHerbert Dürr libraries = ['ssl', 'crypto'], 88*d3c32b8cSHerbert Dürr depends = ['socketmodule.h']), ) 89*d3c32b8cSHerbert Dürr else: 90*d3c32b8cSHerbert Dürr@@ -858,6 +860,7 @@ 91*d3c32b8cSHerbert Dürr exts.append( Extension('_hashlib', ['_hashopenssl.c'], 92*d3c32b8cSHerbert Dürr include_dirs = ssl_incs, 93*d3c32b8cSHerbert Dürr library_dirs = ssl_libs, 94*d3c32b8cSHerbert Dürr+ extra_link_args = ['-Wl,--exclude-libs,ALL'], 95*d3c32b8cSHerbert Dürr libraries = ['ssl', 'crypto']) ) 96*d3c32b8cSHerbert Dürr else: 97*d3c32b8cSHerbert Dürr print ("warning: openssl 0x%08x is too old for _hashlib" % 98