Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

_fixup_sdk_dirs in setup.py will become redundant #1897

Closed
zooba opened this issue Jun 17, 2022 · 4 comments
Closed

_fixup_sdk_dirs in setup.py will become redundant #1897

zooba opened this issue Jun 17, 2022 · 4 comments

Comments

@zooba
Copy link
Contributor

zooba commented Jun 17, 2022

Just as an FYI, I submitted the patch for distutils/setuptools that will make this hack in your setup.py redundant:

def _fixup_sdk_dirs(self):

The PR is at pypa/distutils#153 (and should go into setuptools after that) for reference.

I haven't tried, but I believe the code in your setup.py will still work, and none of the asserts will trigger. So you may not notice anything at all (unless you happen to see that there are twice as many include/lib directories in the compiler commands). There's no good way to detect that it's running with a fixed setuptools, so I guess just be aware that if the asserts do start triggering, it may be intentional and they can be relaxed a bit.

@mhammond
Copy link
Owner

Thanks for the heads-up Steve!

@mhammond
Copy link
Owner

pywin32's build will now fail unless setuptools is fairly recent, so once that lands, I'll just force a requirement on that new version. I'm sure you can imagine how much I want to kill some of the crazy stuff setup.py does :)

@kxrob
Copy link
Collaborator

kxrob commented Aug 21, 2022

#1936 includes removal of the _fixup_sdk_dirs() mechanism.

kxrob added a commit to kxrob/pywin32 that referenced this issue Aug 22, 2022
Newer distutils / setuptools versions already use and expose
the MSVC & SDK dirs - taken from vcvarsall.bat . We need and
should not use a different mechanism anymore.
(Include & lib dirs of 2 different SDK kits at the same time
were seen on compiler command lines on github CI - for the last
months at least.)
@Avasam
Copy link
Collaborator

Avasam commented Mar 12, 2024

@mhammond @zooba Should this have been closed by #1936 ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants