Munge depends files to have absolute paths.
Look in both moddirlist and incdirlist, since a .h could be in either.
This commit is contained in:
parent
c18fde5d82
commit
340043ea79
9
setup.py
9
setup.py
|
@ -105,6 +105,8 @@ class PyBuildExt(build_ext):
|
||||||
moddirlist.append(macmoddir)
|
moddirlist.append(macmoddir)
|
||||||
incdirlist.append('./Mac/Include')
|
incdirlist.append('./Mac/Include')
|
||||||
|
|
||||||
|
alldirlist = moddirlist + incdirlist
|
||||||
|
|
||||||
# Fix up the paths for scripts, too
|
# Fix up the paths for scripts, too
|
||||||
self.distribution.scripts = [os.path.join(srcdir, filename)
|
self.distribution.scripts = [os.path.join(srcdir, filename)
|
||||||
for filename in self.distribution.scripts]
|
for filename in self.distribution.scripts]
|
||||||
|
@ -112,6 +114,9 @@ class PyBuildExt(build_ext):
|
||||||
for ext in self.extensions[:]:
|
for ext in self.extensions[:]:
|
||||||
ext.sources = [ find_module_file(filename, moddirlist)
|
ext.sources = [ find_module_file(filename, moddirlist)
|
||||||
for filename in ext.sources ]
|
for filename in ext.sources ]
|
||||||
|
if ext.depends is not None:
|
||||||
|
ext.depends = [find_module_file(filename, alldirlist)
|
||||||
|
for filename in ext.depends]
|
||||||
ext.include_dirs.append( '.' ) # to get config.h
|
ext.include_dirs.append( '.' ) # to get config.h
|
||||||
for incdir in incdirlist:
|
for incdir in incdirlist:
|
||||||
ext.include_dirs.append( os.path.join(srcdir, incdir) )
|
ext.include_dirs.append( os.path.join(srcdir, incdir) )
|
||||||
|
@ -386,7 +391,7 @@ class PyBuildExt(build_ext):
|
||||||
|
|
||||||
# socket(2)
|
# socket(2)
|
||||||
exts.append( Extension('_socket', ['socketmodule.c'],
|
exts.append( Extension('_socket', ['socketmodule.c'],
|
||||||
depends = ['Modules/socketmodule.h']) )
|
depends = ['socketmodule.h']) )
|
||||||
# Detect SSL support for the socket module (via _ssl)
|
# Detect SSL support for the socket module (via _ssl)
|
||||||
ssl_incs = find_file('openssl/ssl.h', inc_dirs,
|
ssl_incs = find_file('openssl/ssl.h', inc_dirs,
|
||||||
['/usr/local/ssl/include',
|
['/usr/local/ssl/include',
|
||||||
|
@ -404,7 +409,7 @@ class PyBuildExt(build_ext):
|
||||||
include_dirs = ssl_incs,
|
include_dirs = ssl_incs,
|
||||||
library_dirs = ssl_libs,
|
library_dirs = ssl_libs,
|
||||||
libraries = ['ssl', 'crypto'],
|
libraries = ['ssl', 'crypto'],
|
||||||
depends = ['Modules/socketmodule.h']), )
|
depends = ['socketmodule.h']), )
|
||||||
|
|
||||||
# Modules that provide persistent dictionary-like semantics. You will
|
# Modules that provide persistent dictionary-like semantics. You will
|
||||||
# probably want to arrange for at least one of them to be available on
|
# probably want to arrange for at least one of them to be available on
|
||||||
|
|
Loading…
Reference in New Issue