Skip to content

Commit

Permalink
Revert "Bump min setuptools version and remove setup.py (FEniCS#154)"
Browse files Browse the repository at this point in the history
This reverts commit 6eeef93.
  • Loading branch information
dham committed May 5, 2023
1 parent 256c635 commit c5c164b
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[build-system]
requires = ["setuptools>=62", "wheel"]
requires = ["setuptools>=58", "wheel"]

build-backend = "setuptools.build_meta"
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ include_package_data = True
zip_safe = False
python_requires = >= 3.8
setup_requires =
setuptools >= 62
setuptools >= 58
wheel
install_requires =
numpy
Expand Down
16 changes: 16 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import setuptools

try:
import pip

from packaging import version
if version.parse(pip.__version__) < version.parse("21.3"):
# Issue with older version of pip https://github.com/pypa/pip/issues/7953
import site
import sys
site.ENABLE_USER_SITE = "--user" in sys.argv[1:]

except ImportError:
pass

setuptools.setup()

0 comments on commit c5c164b

Please sign in to comment.