mirror of
https://github.com/Cantera/cantera.git
synced 2025-02-25 18:55:29 -06:00
Fix errors due to setuptools 61.0
Something changed in setuptools that causes the old method of forcing platform-specific wheels to be built to break for certain configurations (specifically, Windows builds with Python 3.7). This alternative approach appears to be more robust. Also increase the logging from 'pip wheel' to help with debugging
This commit is contained in:
2
.github/workflows/main.yml
vendored
2
.github/workflows/main.yml
vendored
@@ -492,7 +492,7 @@ jobs:
|
||||
architecture: x64
|
||||
- name: Install Python dependencies
|
||||
run: |
|
||||
python -m pip install -U pip 'setuptools>=43.0.0' wheel
|
||||
python -m pip install -U pip setuptools wheel
|
||||
python -m pip install scons pypiwin32 numpy ruamel.yaml cython h5py pandas pytest pytest-github-actions-annotate-failures
|
||||
- name: Restore Boost cache
|
||||
uses: actions/cache@v2
|
||||
|
||||
@@ -102,7 +102,7 @@ ext = localenv.LoadableModule(f"cantera/_cantera{module_ext}",
|
||||
obj, LIBPREFIX="", SHLIBSUFFIX=module_ext,
|
||||
SHLIBPREFIX="", LIBSUFFIXES=[module_ext])
|
||||
|
||||
build_cmd = ("$python_cmd_esc -m pip wheel --no-build-isolation --no-deps "
|
||||
build_cmd = ("$python_cmd_esc -m pip wheel -v --no-build-isolation --no-deps "
|
||||
"--wheel-dir=build/python/dist build/python")
|
||||
plat = info['plat'].replace('-', '_').replace('.', '_')
|
||||
wheel_name = (f"Cantera-{env['cantera_version']}-cp{py_version_nodot}"
|
||||
|
||||
@@ -1,5 +1,10 @@
|
||||
from setuptools import setup, Extension
|
||||
from setuptools import setup
|
||||
from setuptools.dist import Distribution
|
||||
|
||||
extension = Extension("cantera._cantera", sources=[])
|
||||
class BinaryDistribution(Distribution):
|
||||
def has_ext_modules(self):
|
||||
return True
|
||||
|
||||
setup(ext_modules=[extension])
|
||||
setup(
|
||||
distclass=BinaryDistribution,
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user