[pycrypto] macOS, pip3 install pycrypto: fatal error: 'gmp.h' file not found?

Martin Falatic martin at falatic.com
Wed Jul 15 07:57:06 UTC 2020


The best way to install pycrypto is not to (it hasn't been updated since
2013).

Instead, use the drop-in replacement pycryptodome! See the docs for more
information and where to find support for it if needed.

https://www.pycryptodome.org/en/latest/ 

On 2020-07-14 22:58, 天上火 wrote:

> macOS:  
> pip3 install pycrypto 
> 
> fatal error: 'gmp.h' file not found? 
> 
> Error message: 
> /////////////////////////////////// 
> 
> xcrun -sdk macosx clang -arch x86_64 -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -fwrapv -Wall -iwithsysroot/System/Library/Frameworks/System.framework/PrivateHeaders -iwithsysroot/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.7/Headers -std=c99 -O3 -fomit-frame-pointer -Isrc/ -I/usr/include/ -I/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.7/include/python3.7m -c src/_fastmath.c -o build/temp.macosx-10.14-x86_64-3.7/src/_fastmath.o 
> src/_fastmath.c:36:11: fatal error: 'gmp.h' file not found 
> # include <gmp.h> 
> ^~~~~~~ 
> 1 error generated. 
> error: command 'xcrun' failed with exit status 1 
> 
> /////////////////////////////////// 
> 
> How to install pycrypto ? 
> 
> -------------------------------------------------- 
> Best regards 
> _______________________________________________
> pycrypto mailing list
> pycrypto at lists.dlitz.net
> http://lists.dlitz.net/cgi-bin/mailman/listinfo/pycrypto
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.dlitz.net/pipermail/pycrypto/attachments/20200715/86fc622a/attachment.htm>


More information about the pycrypto mailing list