Skip to content

Commit 60b73ec

Browse files
bnavigatorionelmc
authored andcommitted
migrate build command from distutils to setuptools
1 parent 5503d74 commit 60b73ec

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

setup.py

+5-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
#!/usr/bin/env python
22

33
import re
4-
from distutils.command.build import build
54
from glob import glob
65
from itertools import chain
76
from os.path import basename
@@ -12,6 +11,11 @@
1211
from setuptools import Command
1312
from setuptools import find_packages
1413
from setuptools import setup
14+
try:
15+
# https://setuptools.pypa.io/en/latest/deprecated/distutils-legacy.html
16+
from setuptools.command.build import build
17+
except ImportError:
18+
from distutils.command.build import build
1519
from setuptools.command.develop import develop
1620
from setuptools.command.easy_install import easy_install
1721
from setuptools.command.install_lib import install_lib

0 commit comments

Comments
 (0)