Hi!
So I'm having trouble rebuilding pywin32. It seems like the Windows 10 SDK is
different from what is expected by the latest version of pywin32. Is that
correct? Should I just attempt to fix it myself, or is there something obvious
I'm doing wrong? Here's what happens if I build normally.
Found version 0xa00 in C:\Program Files (x86)\Windows
Kits\10\include\10.0.10586.0\shared\SDKDDKVER.H
setup.py:1207: ResourceWarning: unclosed file <_io.TextIOWrapper
name='C:\\Program Files (x86)\\Windows
Kits\\10\\include\\10.0.10586.0\\shared\\SDKDDKVER.H' mode='r'
encoding='cp1252'>
why = self._why_cant_build_extension(ext)
building 'win32job' extension
swigging win32/src/win32job.i to win32/src/win32job_swig.cpp
D:\projects\ctg\python3\ctg\src\vendor\PythonExtensions\pywin32\swig\swig.exe
-python -c++ -dnone -DSWIG_PY64BIT -o
D:\projects\ctg\python3\ctg\src\vendor\PythonExtensions\pywin32\win32\src\win32job_swig.cpp
D:\projects\ctg\python3\ctg\src\vendor\PythonExtensions\pywin32\win32\src\win32job.i
Generating wrappers for Python
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\amd64\cl.exe /c
/nologo /Od /MDd /W3 /GS- /Z7 /D_DEBUG -DDISTUTILS_BUILD
-D_CRT_SECURE_NO_WARNINGS -Icom/win32com/src/include -Iwin32/src
-Id:\projects\ctg\python3\ctg\publish\python\include
-Id:\projects\ctg\python3\ctg\publish\python\include
/TpD:\projects\ctg\python3\ctg\src\vendor\PythonExtensions\pywin32\win32\src\win32job_swig.cpp
/Fobuild\temp.win-amd64-3.5-pydebug\Debug\win32/src/win32job_swig.obj
/Fdbuild\temp.win-amd64-3.5-pydebug\Debug\win32job_vc.pdb /EHsc /DUNICODE
/D_UNICODE /DWINNT
win32job_swig.cpp
D:\projects\ctg\python3\ctg\src\vendor\PythonExtensions\pywin32\win32\src\win32job_swig.cpp(1247):
error C2065: 'JOB_OBJECT_RESERVED_LIMIT_VALID_FLAGS': undeclared identifier
D:\projects\ctg\python3\ctg\src\vendor\PythonExtensions\pywin32\win32\src\win32job_swig.cpp(1247):
error C2660: 'PyDict_SetItemString': function does not take 2 arguments
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio
14.0\\VC\\BIN\\amd64\\cl.exe' failed with exit status 2xc
If I delete the following line (462) from win32job.i, I can get a fair bit
further:
#define JOB_OBJECT_RESERVED_LIMIT_VALID_FLAGS
JOB_OBJECT_RESERVED_LIMIT_VALID_FLAGS
Then, I get a bunch of errors that look like this:
building 'axdebug' extension
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\amd64\cl.exe /c
/nologo /Od /W3 /GS- /Z7 /D_DEBUG /MDd -DDISTUTILS_BUILD
-D_CRT_SECURE_NO_WARNINGS -Icom/win32com/src/include -Iwin32/src
-Id:\projects\ctg\python3\ctg\publish\python\include
-Id:\projects\ctg\python3\ctg\publish\python\include
/TpD:\projects\ctg\python3\ctg\src\vendor\PythonExtensions\pywin32\com\win32comext\axdebug\src\AXDebug.cpp
/Fobuild\temp.win-amd64-3.5-pydebug\Debug\com/win32comext/axdebug/src/AXDebug.obj
/Fpbuild\temp.win-amd64-3.5-pydebug\Debug\axdebug.pch
/Fdbuild\temp.win-amd64-3.5-pydebug\Debug\axdebug_vc.pdb /EHsc /DUNICODE
/D_UNICODE /DWINNT
AXDebug.cpp
d:\projects\ctg\python3\ctg\src\vendor\pythonextensions\pywin32\com\win32comext\axdebug\src\stdafx.h(32):
error C2365: 'DBGPROP_ATTRIB_NO_ATTRIB': redefinition; previous definition was
'enumerator'
C:\Program Files (x86)\Windows Kits\10\include\10.0.10586.0\um\dbgprop.h(137):
note: see declaration of 'DBGPROP_ATTRIB_NO_ATTRIB'
d:\projects\ctg\python3\ctg\src\vendor\pythonextensions\pywin32\com\win32comext\axdebug\src\stdafx.h(33):
error C2365: 'DBGPROP_ATTRIB_VALUE_IS_INVALID': redefinition; previous
definition was 'enumerator'
If I go into com/win32comext/AXDebug/src/stdafx.h, and change line 29 from:
#if defined(__REQUIRED_RPCNDR_H_VERSION__)
To
#if 0
Then I can get even further. But then it dies again later, complaining about
undefined symbols. I can fix that by going to line 369 of AXDebug.cpp, and
changing them from this:
ADD_CONSTANT(EX_DBGPROP_INFO_ID); // @const
axdebug|EX_DBGPROP_INFO_ID|
ADD_CONSTANT(EX_DBGPROP_INFO_NTYPE); // @const
axdebug|EX_DBGPROP_INFO_NTYPE|
ADD_CONSTANT(EX_DBGPROP_INFO_NVALUE); // @const
axdebug|EX_DBGPROP_INFO_NVALUE|
ADD_CONSTANT(EX_DBGPROP_INFO_LOCKBYTES); // @const
axdebug|EX_DBGPROP_INFO_LOCKBYTES|
ADD_CONSTANT(EX_DBGPROP_INFO_DEBUGEXTPROP); // @const
axdebug|EX_DBGPROP_INFO_DEBUGEXTPROP|
To this:
ADD_CONSTANT(EX_PROP_INFO_ID); // @const
axdebug|EX_PROP_INFO_ID|
ADD_CONSTANT(EX_PROP_INFO_NTYPE); // @const
axdebug|EX_PROP_INFO_NTYPE|
ADD_CONSTANT(EX_PROP_INFO_NVALUE); // @const
axdebug|EX_PROP_INFO_NVALUE|
ADD_CONSTANT(EX_PROP_INFO_LOCKBYTES); // @const
axdebug|EX_PROP_INFO_LOCKBYTES|
ADD_CONSTANT(EX_PROP_INFO_DEBUGEXTPROP); // @const
axdebug|EX_PROP_INFO_DEBUGEXTPROP|
Fixing that, it dies in linking axdebug. And at this point, I have to ask if
I'm doing something wrong. We should be on the latest published version of
pywin32, so I'm a bit surprised that I'm needing to fix all these compile
errors. Is that expected?
Thanks for any assistance!
Chris
________________________________
This e-mail may contain CONFIDENTIAL AND PROPRIETARY INFORMATION and/or
PRIVILEGED AND CONFIDENTIAL COMMUNICATION intended solely for the recipient
and, therefore, may not be retransmitted to any party outside of the
recipient's organization without the prior written consent of the sender. If
you have received this e-mail in error please notify the sender immediately by
telephone or reply e-mail and destroy the original message without making a
copy. Deep Silver, Inc. accepts no liability for any losses or damages
resulting from infected e-mail transmissions and viruses in e-mail attachments.
_______________________________________________
python-win32 mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-win32