Remove using of distutils (#1964)
* Remove using of distutils * Upgrade setuptools to fix CI * Use Python 3.7 in build_wheel.sh
This commit is contained in:
2
.github/workflows/PyPI-publishing.yml
vendored
2
.github/workflows/PyPI-publishing.yml
vendored
@@ -109,7 +109,7 @@ jobs:
|
|||||||
|
|
||||||
- name: '🛠️ pip dependencies'
|
- name: '🛠️ pip dependencies'
|
||||||
run: |
|
run: |
|
||||||
pip install setuptools wheel
|
pip install --upgrade setuptools wheel
|
||||||
|
|
||||||
- name: '🚧 Build distribution'
|
- name: '🚧 Build distribution'
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|||||||
@@ -4,11 +4,7 @@ set -e -x
|
|||||||
cd bindings/python
|
cd bindings/python
|
||||||
|
|
||||||
# Compile wheels
|
# Compile wheels
|
||||||
if [ -f /opt/python/cp36-cp36m/bin/python ];then
|
python3.7 setup.py bdist_wheel $@
|
||||||
/opt/python/cp36-cp36m/bin/python setup.py bdist_wheel $@
|
|
||||||
else
|
|
||||||
python3 setup.py bdist_wheel $@
|
|
||||||
fi
|
|
||||||
cd dist
|
cd dist
|
||||||
|
|
||||||
# We can't repair an aarch64 wheel on x64 hosts
|
# We can't repair an aarch64 wheel on x64 hosts
|
||||||
|
|||||||
@@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
from __future__ import print_function
|
from __future__ import print_function
|
||||||
import glob
|
import glob
|
||||||
|
import logging
|
||||||
import os
|
import os
|
||||||
import subprocess
|
import subprocess
|
||||||
import shutil
|
import shutil
|
||||||
@@ -10,13 +11,14 @@ import sys
|
|||||||
import platform
|
import platform
|
||||||
import setuptools
|
import setuptools
|
||||||
|
|
||||||
from distutils import log
|
from setuptools import setup
|
||||||
from distutils.core import setup
|
from sysconfig import get_platform
|
||||||
from distutils.util import get_platform
|
from setuptools.command.build import build
|
||||||
from distutils.command.build import build
|
from setuptools.command.sdist import sdist
|
||||||
from distutils.command.sdist import sdist
|
|
||||||
from setuptools.command.bdist_egg import bdist_egg
|
from setuptools.command.bdist_egg import bdist_egg
|
||||||
|
|
||||||
|
log = logging.getLogger(__name__)
|
||||||
|
|
||||||
SYSTEM = sys.platform
|
SYSTEM = sys.platform
|
||||||
|
|
||||||
# sys.maxint is 2**31 - 1 on both 32 and 64 bit mingw
|
# sys.maxint is 2**31 - 1 on both 32 and 64 bit mingw
|
||||||
|
|||||||
Reference in New Issue
Block a user