[Cryptography-dev] problem installing on Mac OS X 10.8.5
Paul Kehrer
paul.l.kehrer at gmail.com
Tue Apr 22 02:04:12 CEST 2014
Does it work if you bind against system OpenSSL (don’t pass any flags)? This looks like the same problem described here: https://github.com/pyca/cryptography/issues/693
On April 21, 2014 at 1:29:13 PM, Greg Wilson (gvwilson at third-bit.com) wrote:
Hi,
Trying to install cryptography so that I can install Scrapy; as per
https://cryptography.io/en/latest/installation/, I'm using:
$ brewinstall openssl
Warning: openssl-1.0.1e already installed
and then:
$ env ARCHFLAGS="-arch x86_64" LDFLAGS="-L/usr/local/opt/openssl/lib"
CFLAGS="-I/usr/local/opt/openssl/include" pip install cryptography
Error message is below; note that I have installed libffi using "brew
install libffi", and
/usr/local/Cellar/libffi/3.0.13/lib/pkgconfig/libffi.pc exists. Pointers
would be welcome...
Thanks,
Greg
--------
Downloading/unpacking cryptography
Running setup.py egg_info for package cryptography
OS/X: confusion between 'cc' versus 'gcc' (see issue 123)
will not use '__thread' in the C code
Installed
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg
building '_Cryptography_cffi_684bb40axf342507b' extension
/usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
-I/usr/local/opt/openssl/include -arch x86_64
-I/Users/gwilson/anaconda/include/python2.7 -c
cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_684bb40axf342507b.c
-o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_684bb40axf342507b.o
/usr/bin/clang -bundle -undefined dynamic_lookup
-L/Users/gwilson/anaconda/lib -L/usr/local/opt/openssl/lib
-I/usr/local/opt/openssl/include -arch x86_64 -arch x86_64
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_684bb40axf342507b.o
-L/Users/gwilson/anaconda/lib -o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_684bb40axf342507b.so
building '_Cryptography_cffi_8f86901cxc1767c5a' extension
/usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
-I/usr/local/opt/openssl/include -arch x86_64
-I/Users/gwilson/anaconda/include/python2.7 -c
cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_8f86901cxc1767c5a.c
-o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_8f86901cxc1767c5a.o
/usr/bin/clang -bundle -undefined dynamic_lookup
-L/Users/gwilson/anaconda/lib -L/usr/local/opt/openssl/lib
-I/usr/local/opt/openssl/include -arch x86_64 -arch x86_64
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_8f86901cxc1767c5a.o
-L/Users/gwilson/anaconda/lib -o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_8f86901cxc1767c5a.so
building '_Cryptography_cffi_48bbf0ebx93c91939' extension
/usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
-I/usr/local/opt/openssl/include -arch x86_64
-I/Users/gwilson/anaconda/include/python2.7 -c
cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.c
-o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.o
/usr/bin/clang -bundle -undefined dynamic_lookup
-L/Users/gwilson/anaconda/lib -L/usr/local/opt/openssl/lib
-I/usr/local/opt/openssl/include -arch x86_64 -arch x86_64
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.o
-L/Users/gwilson/anaconda/lib -lcrypto -lssl -o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.so
Traceback (most recent call last):
File "<string>", line 16, in <module>
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/setup.py",
line 156, in <module>
"test": PyTest,
File "/Users/gwilson/anaconda/lib/python2.7/distutils/core.py",
line 152, in setup
dist.run_commands()
File "/Users/gwilson/anaconda/lib/python2.7/distutils/dist.py",
line 953, in run_commands
self.run_command(cmd)
File "/Users/gwilson/anaconda/lib/python2.7/distutils/dist.py",
line 972, in run_command
cmd_obj.run()
File "<string>", line 14, in replacement_run
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/egg_info.py",
line 259, in find_sources
mm.run()
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/egg_info.py",
line 325, in run
self.add_defaults()
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/egg_info.py",
line 361, in add_defaults
sdist.add_defaults(self)
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/sdist.py",
line 199, in add_defaults
build_py = self.get_finalized_command('build_py')
File "/Users/gwilson/anaconda/lib/python2.7/distutils/cmd.py",
line 312, in get_finalized_command
cmd_obj.ensure_finalized()
File "/Users/gwilson/anaconda/lib/python2.7/distutils/cmd.py",
line 109, in ensure_finalized
self.finalize_options()
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/build_py.py",
line 73, in finalize_options
_build_py.finalize_options(self)
File
"/Users/gwilson/anaconda/lib/python2.7/distutils/command/build_py.py",
line 46, in finalize_options
('force', 'force'))
File "/Users/gwilson/anaconda/lib/python2.7/distutils/cmd.py",
line 298, in set_undefined_options
src_cmd_obj.ensure_finalized()
File "/Users/gwilson/anaconda/lib/python2.7/distutils/cmd.py",
line 109, in ensure_finalized
self.finalize_options()
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/setup.py",
line 75, in finalize_options
OpenSSLBinding().ffi.verifier.get_extension(),
File "cryptography/hazmat/bindings/openssl/binding.py", line 83,
in __init__
self._ensure_ffi_initialized()
File "cryptography/hazmat/bindings/openssl/binding.py", line 99,
in _ensure_ffi_initialized
libraries)
File "cryptography/hazmat/bindings/utils.py", line 77, in build_ffi
ext_package="cryptography",
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg/cffi/api.py",
line 341, in verify
lib = self.verifier.load_library()
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg/cffi/verifier.py",
line 75, in load_library
return self._load_library()
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg/cffi/verifier.py",
line 151, in _load_library
return self._vengine.load_library()
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg/cffi/vengine_cpy.py",
line 138, in load_library
raise ffiplatform.VerificationError(error)
cffi.ffiplatform.VerificationError: importing
'/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.so':
dlopen(/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.so,
2): Library not loaded: libcrypto.1.0.0.dylib
Referenced from:
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.so
Reason: image not found
Complete output from command python setup.py egg_info:
OS/X: confusion between 'cc' versus 'gcc' (see issue 123)
will not use '__thread' in the C code
Installed
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg
running egg_info
creating pip-egg-info/cryptography.egg-info
writing requirements to pip-egg-info/cryptography.egg-info/requires.txt
writing pip-egg-info/cryptography.egg-info/PKG-INFO
writing top-level names to pip-egg-info/cryptography.egg-info/top_level.txt
writing dependency_links to
pip-egg-info/cryptography.egg-info/dependency_links.txt
writing manifest file 'pip-egg-info/cryptography.egg-info/SOURCES.txt'
warning: manifest_maker: standard file '-c' not found
running build_ext
building '_Cryptography_cffi_684bb40axf342507b' extension
creating
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography
creating
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat
creating
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives
creating
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives/__pycache__
/usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
-I/usr/local/opt/openssl/include -arch x86_64
-I/Users/gwilson/anaconda/include/python2.7 -c
cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_684bb40axf342507b.c
-o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_684bb40axf342507b.o
/usr/bin/clang -bundle -undefined dynamic_lookup
-L/Users/gwilson/anaconda/lib -L/usr/local/opt/openssl/lib
-I/usr/local/opt/openssl/include -arch x86_64 -arch x86_64
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_684bb40axf342507b.o
-L/Users/gwilson/anaconda/lib -o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_684bb40axf342507b.so
running build_ext
building '_Cryptography_cffi_8f86901cxc1767c5a' extension
/usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
-I/usr/local/opt/openssl/include -arch x86_64
-I/Users/gwilson/anaconda/include/python2.7 -c
cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_8f86901cxc1767c5a.c
-o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_8f86901cxc1767c5a.o
/usr/bin/clang -bundle -undefined dynamic_lookup
-L/Users/gwilson/anaconda/lib -L/usr/local/opt/openssl/lib
-I/usr/local/opt/openssl/include -arch x86_64 -arch x86_64
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_8f86901cxc1767c5a.o
-L/Users/gwilson/anaconda/lib -o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/primitives/__pycache__/_Cryptography_cffi_8f86901cxc1767c5a.so
running build_ext
building '_Cryptography_cffi_48bbf0ebx93c91939' extension
creating
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/cryptography
creating
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/cryptography/hazmat
creating
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/cryptography/hazmat/bindings
creating
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/cryptography/hazmat/bindings/__pycache__
/usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
-I/usr/local/opt/openssl/include -arch x86_64
-I/Users/gwilson/anaconda/include/python2.7 -c
cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.c
-o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.o
/usr/bin/clang -bundle -undefined dynamic_lookup
-L/Users/gwilson/anaconda/lib -L/usr/local/opt/openssl/lib
-I/usr/local/opt/openssl/include -arch x86_64 -arch x86_64
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.o
-L/Users/gwilson/anaconda/lib -lcrypto -lssl -o
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.so
Traceback (most recent call last):
File "<string>", line 16, in <module>
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/setup.py",
line 156, in <module>
"test": PyTest,
File "/Users/gwilson/anaconda/lib/python2.7/distutils/core.py", line
152, in setup
dist.run_commands()
File "/Users/gwilson/anaconda/lib/python2.7/distutils/dist.py", line
953, in run_commands
self.run_command(cmd)
File "/Users/gwilson/anaconda/lib/python2.7/distutils/dist.py", line
972, in run_command
cmd_obj.run()
File "<string>", line 14, in replacement_run
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/egg_info.py",
line 259, in find_sources
mm.run()
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/egg_info.py",
line 325, in run
self.add_defaults()
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/egg_info.py",
line 361, in add_defaults
sdist.add_defaults(self)
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/sdist.py",
line 199, in add_defaults
build_py = self.get_finalized_command('build_py')
File "/Users/gwilson/anaconda/lib/python2.7/distutils/cmd.py", line
312, in get_finalized_command
cmd_obj.ensure_finalized()
File "/Users/gwilson/anaconda/lib/python2.7/distutils/cmd.py", line
109, in ensure_finalized
self.finalize_options()
File
"/Users/gwilson/anaconda/lib/python2.7/site-packages/setuptools/command/build_py.py",
line 73, in finalize_options
_build_py.finalize_options(self)
File
"/Users/gwilson/anaconda/lib/python2.7/distutils/command/build_py.py",
line 46, in finalize_options
('force', 'force'))
File "/Users/gwilson/anaconda/lib/python2.7/distutils/cmd.py", line
298, in set_undefined_options
src_cmd_obj.ensure_finalized()
File "/Users/gwilson/anaconda/lib/python2.7/distutils/cmd.py", line
109, in ensure_finalized
self.finalize_options()
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/setup.py",
line 75, in finalize_options
OpenSSLBinding().ffi.verifier.get_extension(),
File "cryptography/hazmat/bindings/openssl/binding.py", line 83, in
__init__
self._ensure_ffi_initialized()
File "cryptography/hazmat/bindings/openssl/binding.py", line 99, in
_ensure_ffi_initialized
libraries)
File "cryptography/hazmat/bindings/utils.py", line 77, in build_ffi
ext_package="cryptography",
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg/cffi/api.py",
line 341, in verify
lib = self.verifier.load_library()
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg/cffi/verifier.py",
line 75, in load_library
return self._load_library()
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg/cffi/verifier.py",
line 151, in _load_library
return self._vengine.load_library()
File
"/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cffi-0.8.2-py2.7-macosx-10.5-x86_64.egg/cffi/vengine_cpy.py",
line 138, in load_library
raise ffiplatform.VerificationError(error)
cffi.ffiplatform.VerificationError: importing
'/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.so':
dlopen(/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.so,
2): Library not loaded: libcrypto.1.0.0.dylib
Referenced from:
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography/cryptography/hazmat/bindings/__pycache__/_Cryptography_cffi_48bbf0ebx93c91939.so
Reason: image not found
----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in
/private/var/folders/vz/m_8fd1kj2kn9t2gq0d8fqgg00000gn/T/pip_build_gwilson/cryptography
Storing complete log in /Users/gwilson/.pip/pip.log
_______________________________________________
Cryptography-dev mailing list
Cryptography-dev at python.org
https://mail.python.org/mailman/listinfo/cryptography-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/cryptography-dev/attachments/20140421/a186ec9c/attachment-0001.html>
More information about the Cryptography-dev
mailing list