diff setup.py @ 52318:7606466300c1

setup_py: remove IronPython Python 2.7 specific code
author paugier <pierre.augier@univ-grenoble-alpes.fr>
date Thu, 24 Oct 2024 15:13:23 +0200
parents 5d81f4b7e024
children fcc059b1eed0
line wrap: on
line diff
--- a/setup.py	Sat Nov 23 05:50:43 2024 +0100
+++ b/setup.py	Thu Oct 24 15:13:23 2024 +0200
@@ -3,7 +3,6 @@
 import os
 
 import sys
-import platform
 import sysconfig
 
 
@@ -54,26 +53,15 @@
         "Couldn't import standard zlib (incomplete Python install)."
     )
 
-# The base IronPython distribution (as of 2.7.1) doesn't support bz2
-isironpython = False
+
 try:
-    isironpython = (
-        platform.python_implementation().lower().find("ironpython") != -1
-    )
-except AttributeError:
-    pass
+    import bz2
 
-if isironpython:
-    sys.stderr.write("warning: IronPython detected (no bz2 support)\n")
-else:
-    try:
-        import bz2
-
-        bz2.BZ2Compressor  # silence unused import warning
-    except ImportError:
-        raise SystemExit(
-            "Couldn't import standard bz2 (incomplete Python install)."
-        )
+    bz2.BZ2Compressor  # silence unused import warning
+except ImportError:
+    raise SystemExit(
+        "Couldn't import standard bz2 (incomplete Python install)."
+    )
 
 ispypy = "PyPy" in sys.version