[Python-Dev] Re: Python 3.7.4, Visual Studio versions for building modules from source
On 23Jul2019 0812, Kacvinsky, Tom wrote: Tests passed once I used the right Visual Studio Command prompt. I was using the x64 Native toolchain command shell. Once I switched to the generic command shell, all is well. Thanks for the lick in the right direction, it got me to thinking that even though the tools are installed, I should try different Visual Studio shells. In general, it's better to not use the VS command shell at all. distutils figures out what it needs (setuptools does a better job, for what its worth). If you are going to use the shell, also set DISTUTILS_USE_SDK=1 to disable the automatic detection. In the wrong shell you'll get a broken build, but it might have unblocked you in this case. Cheers, Steve ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/MZXX5YFIHUQ6VHAM26WZHWHRTXNVXNME/
[Python-Dev] Re: Python 3.7.4, Visual Studio versions for building modules from source
> -Original Message- > From: Steve Dower > Sent: Monday, July 22, 2019 11:36 PM > To: Kacvinsky, Tom ; python-dev@python.org > Subject: [Python-Dev] Re: Python 3.7.4, Visual Studio versions for building > modules from source > This is probably not the best place to ask, though I can understand why you > ended up here. Please try this command: > > -m test -v test_distutils -m *get_vc* > > If the tests pass, post to distutils-...@python.org or the Packaging category > on https://discuss.python.org/ > > If the tests fail, post the output into a new bug at https://bugs.python.org/ > along with > > If the tests are skipped, you probably did not install the C++ or "Python > Native Development" options for Visual Studio. You can run "Visual Studio > Installer" from Start to change your installed options. Tests passed once I used the right Visual Studio Command prompt. I was using the x64 Native toolchain command shell. Once I switched to the generic command shell, all is well. Thanks for the lick in the right direction, it got me to thinking that even though the tools are installed, I should try different Visual Studio shells. Tom ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/55WQKH6XGVJS7EOQT3LGXBJE2LA7LSEW/
[Python-Dev] Re: Python 3.7.4, Visual Studio versions for building modules from source
On 22.07.2019 18:25, Kacvinsky, Tom wrote: HI, Not sure if this is the right place to ask, but I am trying to build pywin32-224 from source for Python 3.7.4. I think this might be the right list as this seems to be a generic problem I am having, but I want to focus on one particular module. First, I know I could get this via 'pip install', but I want to build from source to see what it takes in terms of the Windows SDK and Visual Studio versions for some other work I am doing. I am using Python 3.7.4, and I have Visual Studio 2017 15.9 (released July of this year). I see this when running 'python setup.y build': error: Microsoft Visual C++ 14.1 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/ I have tried various compilers from that link (VS 2015, VS 2017, and even VS 2019), but no joy. I also have the Windows SDK 8.1 and 10 installed (pywin32 wants the 8.1 SDK) Does anyone have any ideas as to what I am doing wrong, or if there is some weird underlying issue with setuptools and/or distutils? Distutils supports the same compiler setup that is used to build Python itself. As such, it can be seen in PCBuild/readme.txt in the source code (https://github.com/python/cpython/blob/3.7/PCbuild/readme.txt). If the error says that "Microsoft Visual C++ 14.1 is required", be sure to select "v141 tools" in VS installer (readme.txt doesn't say this explicitly but it's a mandatory component when selecting VC++ support). Setuptools supports more compiler setups. They don't see to be listed in the docs but are listed in https://github.com/pypa/setuptools/blob/master/setuptools/msvc.py . --- Last time I checked, the information about supported compiler setups was gathered at https://wiki.python.org/moin/WindowsCompilers. I see that it doesn't have an entry for MSVC 14.1. Documentation on distutils.msvccompiler (https://docs.python.org/3/distutils/apiref.html?highlight=msvccompiler#module-distutils.msvccompiler) also mentions versions but it's severely outdated. Should it refer to readme.txt? -- Regards, Ivan ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/SJPMTBXZWVKPZ72C5T52DRBG6KZWE77J/
[Python-Dev] Re: Python 3.7.4, Visual Studio versions for building modules from source
On 22Jul.2019 0825, Kacvinsky, Tom wrote: > HI, > > Not sure if this is the right place to ask, but I am trying to build > pywin32-224 from source for Python 3.7.4. I think this might > be the right list as this seems to be a generic problem I am having, but I > want to focus on one particular module. First, I know > I could get this via 'pip install', but I want to build from source to see > what it takes in terms of the Windows SDK and Visual Studio > versions for some other work I am doing. This is probably not the best place to ask, though I can understand why you ended up here. Please try this command: -m test -v test_distutils -m *get_vc* If the tests pass, post to distutils-...@python.org or the Packaging category on https://discuss.python.org/ If the tests fail, post the output into a new bug at https://bugs.python.org/ along with If the tests are skipped, you probably did not install the C++ or "Python Native Development" options for Visual Studio. You can run "Visual Studio Installer" from Start to change your installed options. Cheers, Steve ___ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/L25BIUGNGBYTPJ6ZKG5KGWGNYLYYW2UE/