Put .lib files for .pyd modules in built/lib, so they are packaged into the SDK

This commit is contained in:
rdb 2015-12-06 15:16:48 +01:00
parent eb2c9f51f5
commit 1bbfc1d9f6

View File

@ -1498,7 +1498,7 @@ def CompileLink(dll, obj, opts):
if subsystem: if subsystem:
cmd += " /SUBSYSTEM:" + subsystem cmd += " /SUBSYSTEM:" + subsystem
if dll.endswith(".dll"): if dll.endswith(".dll") or dll.endswith(".pyd"):
cmd += ' /IMPLIB:' + GetOutputDir() + '/lib/' + os.path.splitext(os.path.basename(dll))[0] + ".lib" cmd += ' /IMPLIB:' + GetOutputDir() + '/lib/' + os.path.splitext(os.path.basename(dll))[0] + ".lib"
for (opt, dir) in LIBDIRECTORIES: for (opt, dir) in LIBDIRECTORIES:
@ -1506,10 +1506,8 @@ def CompileLink(dll, obj, opts):
cmd += ' /LIBPATH:' + BracketNameWithQuotes(dir) cmd += ' /LIBPATH:' + BracketNameWithQuotes(dir)
for x in obj: for x in obj:
if x.endswith(".dll"): if x.endswith(".dll") or x.endswith(".pyd"):
cmd += ' ' + GetOutputDir() + '/lib/' + os.path.splitext(os.path.basename(x))[0] + ".lib" cmd += ' ' + GetOutputDir() + '/lib/' + os.path.splitext(os.path.basename(x))[0] + ".lib"
elif x.endswith(".pyd"):
cmd += ' ' + os.path.splitext(x)[0] + ".lib"
elif x.endswith(".lib"): elif x.endswith(".lib"):
dname = os.path.splitext(os.path.basename(x))[0] + ".dll" dname = os.path.splitext(os.path.basename(x))[0] + ".dll"
if (GetOrigExt(x) != ".ilb" and os.path.exists(GetOutputDir()+"/bin/" + dname)): if (GetOrigExt(x) != ".ilb" and os.path.exists(GetOutputDir()+"/bin/" + dname)):
@ -1566,10 +1564,8 @@ def CompileLink(dll, obj, opts):
cmd += ' /LIBPATH:' + BracketNameWithQuotes(dir) cmd += ' /LIBPATH:' + BracketNameWithQuotes(dir)
for x in obj: for x in obj:
if x.endswith(".dll"): if x.endswith(".dll") or x.endswith(".pyd"):
cmd += ' ' + GetOutputDir() + '/lib/' + os.path.splitext(os.path.basename(x))[0] + ".lib" cmd += ' ' + GetOutputDir() + '/lib/' + os.path.splitext(os.path.basename(x))[0] + ".lib"
elif x.endswith(".pyd"):
cmd += ' ' + os.path.splitext(x)[0] + ".lib"
elif x.endswith(".lib"): elif x.endswith(".lib"):
dname = os.path.splitext(dll)[0]+".dll" dname = os.path.splitext(dll)[0]+".dll"
if (GetOrigExt(x) != ".ilb" and os.path.exists(GetOutputDir()+"/bin/" + os.path.splitext(os.path.basename(x))[0] + ".dll")): if (GetOrigExt(x) != ".ilb" and os.path.exists(GetOutputDir()+"/bin/" + os.path.splitext(os.path.basename(x))[0] + ".dll")):