From dcc5c00a3db79d0db7ecc78d38306ea8e6ff5c01 Mon Sep 17 00:00:00 2001 From: Steve Dower Date: Wed, 24 Aug 2022 00:32:20 +0100 Subject: [PATCH] Ensure cfg is removed, and add a message --- cibuildwheel/windows.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cibuildwheel/windows.py b/cibuildwheel/windows.py index 31207efb..5c2d1f0a 100644 --- a/cibuildwheel/windows.py +++ b/cibuildwheel/windows.py @@ -174,6 +174,8 @@ def setup_setuptools_cross_compile( f"Unable to configure setuptools for cross-compiling because {distutils_cfg} is a directory" ) return + else: + atexit.register(lambda: distutils_cfg.unlink) # Ensure our additional import libraries are made available, and explicitly # set the platform name @@ -183,6 +185,8 @@ def setup_setuptools_cross_compile( distutils_cfg.write_text( textwrap.dedent( f"""\ + # I am a temporary configuration file generated by cibuildwheel. + # Please remove me or I will likely break your other builds. [build] plat_name={plat_name} [build_ext]