Python >> Tutoriel Python >  >> Python Tag >> MySQL

Impossible d'installer mysql-python avec pip sur MacOS 10.12.4

Résolu avec ça

brew install mysql
pip install MySQL-python

Si vous avez toujours échoué avec quelque chose comme "Échec de la roue de construction pour mysql-python", essayez

LDFLAGS=-L/usr/local/opt/openssl/lib pip install mysql-python

qui fonctionne comme un charme pour moi.


Cela a fonctionné pour moi (macOS Mojave 10.14.2):

brew install [email protected]
brew link --force [email protected]
brew install mysql-client
LDFLAGS=-L/usr/local/opt/openssl/lib pip install mysql-python