summaryrefslogtreecommitdiff
path: root/setup.py
diff options
context:
space:
mode:
authorChristian Heimes <cheimes@redhat.com>2021-02-08 15:32:58 +0100
committerGitHub <noreply@github.com>2021-02-08 09:32:58 -0500
commit048f7c6cb4cd5a46b252e17c3463d254e1c552ab (patch)
tree275ce484492a40cb7cb7aa6ecde0870720271df6 /setup.py
parent13e7e56c6094639cce1293f88a633270dfbe037c (diff)
downloadcryptography-048f7c6cb4cd5a46b252e17c3463d254e1c552ab.tar.gz
Remove setuptools_rust from install requirement (#5779)
* Remove setuptools_rust from install requirement setuptools_rust is only required for building cryptography. Fixes: https://github.com/pyca/cryptography/issues/5778 Signed-off-by: Christian Heimes <cheimes@redhat.com> * sdist needs setuptools_rust Signed-off-by: Christian Heimes <cheimes@redhat.com>
Diffstat (limited to 'setup.py')
-rw-r--r--setup.py12
1 files changed, 9 insertions, 3 deletions
diff --git a/setup.py b/setup.py
index 9fb3e3200..0142facce 100644
--- a/setup.py
+++ b/setup.py
@@ -39,8 +39,11 @@ with open(os.path.join(src_dir, "cryptography", "__about__.py")) as f:
exec(f.read(), about)
-# `setup_requirements` must be kept in sync with `pyproject.toml`
-setup_requirements = ["cffi>=1.12", "setuptools-rust>=0.11.4"]
+# `install_requirements` and `setup_requirements` must be kept in sync with
+# `pyproject.toml`
+setuptools_rust = "setuptools-rust>=0.11.4"
+install_requirements = ["cffi>=1.12"]
+setup_requirements = install_requirements + [setuptools_rust]
if os.environ.get("CRYPTOGRAPHY_DONT_BUILD_RUST"):
rust_extensions = []
@@ -102,7 +105,7 @@ try:
),
include_package_data=True,
python_requires=">=3.6",
- install_requires=setup_requirements,
+ install_requires=install_requirements,
setup_requires=setup_requirements,
extras_require={
"test": [
@@ -125,6 +128,9 @@ try:
"twine >= 1.12.0",
"sphinxcontrib-spelling >= 4.0.1",
],
+ "sdist": [
+ setuptools_rust,
+ ],
"pep8test": [
"black",
"flake8",