diff --git a/recipes/cryptography/__init__.py b/recipes/cryptography/__init__.py index 9a81b267..fd387999 100644 --- a/recipes/cryptography/__init__.py +++ b/recipes/cryptography/__init__.py @@ -8,6 +8,7 @@ class CryptographyRecipe(CompiledComponentsPythonRecipe): url = 'https://github.com/pyca/cryptography/archive/{version}.tar.gz' depends = [('python2', 'python3crystax'), 'openssl', 'idna', 'pyasn1', 'six', 'setuptools', 'ipaddress', 'cffi'] call_hostpython_via_targetpython = False + patches = ['libpthread.patch'] def get_recipe_env(self, arch): env = super(CryptographyRecipe, self).get_recipe_env(arch) diff --git a/recipes/cryptography/libpthread.patch b/recipes/cryptography/libpthread.patch new file mode 100644 index 00000000..dcdedd80 --- /dev/null +++ b/recipes/cryptography/libpthread.patch @@ -0,0 +1,16 @@ +diff --git a/src/_cffi_src/build_openssl.py b/src/_cffi_src/build_openssl.py +index 35ccd6b..6d5ee4c 100755 +--- a/src/_cffi_src/build_openssl.py ++++ b/src/_cffi_src/build_openssl.py +@@ -42,10 +42,7 @@ def _get_openssl_libraries(platform): + # -lpthread required due to usage of pthread an potential + # existance of a static part containing e.g. pthread_atfork + # (https://github.com/pyca/cryptography/issues/5084) +- if sys.platform == "zos": +- return ["ssl", "crypto"] +- else: +- return ["ssl", "crypto", "pthread"] ++ return ["ssl", "crypto"] + + + def _extra_compile_args(platform):