Setuptools compatibility and Windows fixes #1558
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This replaces
msvc.msvc14_get_vc_env
(themsvc
module has been removed fromsetuptools
in version 74), bydistutils._msvccompiler import _get_vc_env
, which appears to work as a drop-in replacement. IIUC, thesetuptools.msvc
added a bit of functionality for newer compilers compared to the support indistutils
, but those changes have been contributed todistutils
since. This is maybe not the cleanest solution (_get_vc_env
is not really meant for public use), but thedistutils
infrastructure is meant to be used for building Python extension packages, not for generating code at runtime, so we'll always have to work around its limitations a bit.Speaking of which, this PR also fixes a few issues that I noted during testing on my Windows VM, most importantly quoting include/library directory names.
CC @bvogginger, @neworderofjamie
Closes #1557