Skip to content

Commit 05fb3c1

Browse files
authored
Merge pull request #388 from isuruf/build_ext
use build_ext from setuptools
2 parents 1335554 + c9e9aa8 commit 05fb3c1

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

setup.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
import subprocess
44
import sys
55
import platform
6-
from distutils.command.build_ext import build_ext as _build_ext
7-
from distutils.command.build import build as _build
86

97
# Make sure the system has the right Python version.
108
if sys.version_info[:2] < (3, 7):
@@ -28,12 +26,16 @@
2826
try:
2927
from setuptools import setup
3028
from setuptools.command.install import install as _install
29+
from setuptools.command.build_ext import build_ext as _build_ext
30+
from setuptools.command.build import build as _build
3131
except ImportError:
3232
use_setuptools = False
3333

3434
if not use_setuptools:
3535
from distutils.core import setup
3636
from distutils.command.install import install as _install
37+
from distutils.command.build_ext import build_ext as _build_ext
38+
from distutils.command.build import build as _build
3739

3840
cmake_opts = [("PYTHON_BIN", sys.executable),
3941
("CMAKE_INSTALL_RPATH_USE_LINK_PATH", "yes")]

0 commit comments

Comments
 (0)