Mercurial > hg
changeset 51848:3f0db3b6bf14
setup: drop the hack to disable linker warning 4197 on Windows
I don't see this when building on Windows with py3.8 or py3.12, so either the
code was fixed, or (more likely) the compiler stopped warning about it some time
after VS 2008. If we do have to put this back, it would probably be better to
put a `#pragma` in a header file somewhere, and avoid `setuptools` technical
debt.
author | Matt Harbison <mharbison@atto.com> |
---|---|
date | Thu, 05 Sep 2024 16:59:36 -0400 |
parents | a3a9251c6081 |
children | 4dc1fc2b2f3a |
files | setup.py |
diffstat | 1 files changed, 0 insertions(+), 21 deletions(-) [+] |
line wrap: on
line diff
--- a/setup.py Wed Sep 11 00:20:07 2024 +0200 +++ b/setup.py Thu Sep 05 16:59:36 2024 -0400 @@ -1654,27 +1654,6 @@ pass -if os.name == 'nt': - # Allow compiler/linker flags to be added to Visual Studio builds. Passing - # extra_link_args to distutils.extensions.Extension() doesn't have any - # effect. - try: - # setuptools < 65.0 - from distutils import msvccompiler - except ImportError: - from distutils import _msvccompiler as msvccompiler - - msvccompilerclass = msvccompiler.MSVCCompiler - - class HackedMSVCCompiler(msvccompiler.MSVCCompiler): - def initialize(self): - msvccompilerclass.initialize(self) - # "warning LNK4197: export 'func' specified multiple times" - self.ldflags_shared.append('/ignore:4197') - self.ldflags_shared_debug.append('/ignore:4197') - - msvccompiler.MSVCCompiler = HackedMSVCCompiler - packagedata = { 'mercurial': [ 'configitems.toml',