From: Jochen Sprickerhof <jspricke@debian.org>
Date: Mon, 31 Oct 2022 13:09:22 +0100
Subject: Drop custom build_ext class
This was only used to catch exceptions during build (which we probably
don't want in Debian anyhow) and does not work anymore with distutils
from setuptools
---
setup.py | 24 ------------------------
1 file changed, 24 deletions(-)
diff --git a/setup.py b/setup.py
index 2f2a5e3..67ad40d 100644
--- a/setup.py
+++ b/setup.py
@@ -57,7 +57,6 @@ import platform
import sys
from itertools import chain
-from distutils.command.build_ext import build_ext
from distutils.errors import (
CCompilerError, DistutilsExecError, DistutilsPlatformError)
from setuptools import Distribution as _Distribution, Extension, setup
@@ -83,29 +82,6 @@ class BuildFailed(Exception):
self.cause = sys.exc_info()[1] # work around py 2/3 different syntax
-class ve_build_ext(build_ext):
- """This class allows C extension building to fail."""
-
- def run(self):
- try:
- build_ext.run(self)
- except DistutilsPlatformError:
- raise BuildFailed()
-
- def build_extension(self, ext):
- try:
- build_ext.build_extension(self, ext)
- except ext_errors:
- raise BuildFailed()
- except ValueError:
- # this can happen on Windows 64 bit, see Python issue 7511
- if "'path'" in str(sys.exc_info()[1]): # works with both py 2/3
- raise BuildFailed()
- raise
-
-cmdclass['build_ext'] = ve_build_ext
-
-
class Distribution(_Distribution):
def has_ext_modules(self):