惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Jina AI
Jina AI
Google DeepMind News
Google DeepMind News
C
Cybersecurity and Infrastructure Security Agency CISA
T
Tenable Blog
T
The Exploit Database - CXSecurity.com
Latest news
Latest news
G
GRAHAM CLULEY
Project Zero
Project Zero
L
Lohrmann on Cybersecurity
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
C
Cyber Attacks, Cyber Crime and Cyber Security
Application and Cybersecurity Blog
Application and Cybersecurity Blog
Webroot Blog
Webroot Blog
Help Net Security
Help Net Security
TaoSecurity Blog
TaoSecurity Blog
Hacker News: Ask HN
Hacker News: Ask HN
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
N
News and Events Feed by Topic
Cisco Talos Blog
Cisco Talos Blog
T
Tor Project blog
The Hacker News
The Hacker News
The Last Watchdog
The Last Watchdog
C
CXSECURITY Database RSS Feed - CXSecurity.com
V2EX - 技术
V2EX - 技术
S
Secure Thoughts
AWS News Blog
AWS News Blog
W
WeLiveSecurity
云风的 BLOG
云风的 BLOG
V
V2EX
Last Week in AI
Last Week in AI
雷峰网
雷峰网
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
G
Google Developers Blog
P
Palo Alto Networks Blog
A
Arctic Wolf
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
M
MIT News - Artificial intelligence
V
Visual Studio Blog
C
CERT Recently Published Vulnerability Notes
WordPress大学
WordPress大学
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
T
Threatpost
Simon Willison's Weblog
Simon Willison's Weblog
PCI Perspectives
PCI Perspectives
量子位
K
Kaspersky official blog
腾讯CDC
Schneier on Security
Schneier on Security
F
Full Disclosure
S
Schneier on Security

博客园 - 周希

自动驾驶算法评测体系建设实践 Mac上的Redis安装和使用 iPhone手机越狱-逆向砸壳-代码注入 使用Apple Configurator 2提取商店ipa or app文件 使用ATOMac进行Mac自动化测试 WDA支持获取WebView元素 iOS模拟器命令 Android自动化测试探索(七)代码覆盖率统计 Android自动化测试探索(五)代码覆盖率统计 解决ifuse不支持24位UDID问题 Android自动化测试探索(四)uiautomator2简介和使用 iOS自动化探索(十)代码覆盖率统计 Android自动化测试探索(三)Android SDK tools安装、aapt配置以及使用aapt获取apk包名 Android自动化测试探索(二)常用自动化工具 Android自动化测试探索(一)adb详细介绍 关于Mac上使用ideviceinstaller操作iPhoneXR等24位UDID设备报“ERROR: Invalid UDID specified”解决办法 mac下csv乱码解决办法 【Python MySQLdb】Library not loaded: /usr/local/mysql/lib/libmysqlclient.20.dylib解决办法 Pycharm更换主题 Python -- 使用pickle 和 CPickle对数据对象进行归档和解析
Mac安装MySQLdb遇到的坑
周希 · 2019-04-17 · via 博客园 - 周希

最近项目移植, 再进行virtualenv环境安装的时候遇到mysql-python死活安装失败

首先是这个错误:

sh: /usr/local/bin/mysql_config: No such file or directory
Traceback (most recent call last):
  File "setup.py", line 17, in <module>
    metadata, options = get_config()
  File "/Users/jackey/Downloads/MySQL-python-1.2.5/setup_posix.py", line 43, in get_config
    libs = mysql_config("libs_r")
  File "/Users/jackey/Downloads/MySQL-python-1.2.5/setup_posix.py", line 25, in mysql_config
    raise EnvironmentError("%s not found" % (mysql_config.path,))
EnvironmentError: /usr/local/bin/mysql_config not found

解决办法:

export DYLD_LIBRARY_PATH="/usr/local/mysql/lib"

然后又出现这个错误

_mysql.c:44:10: fatal error: 'my_config.h' file not found
#include "my_config.h"
         ^~~~~~~~~~~~~
1 error generated.
error: command 'cc' failed with exit status 1

解决办法:

brew install mysql
brew unlink mysql
brew install mysql-connector-c
sudo sed -i -e 's/libs="$libs -l "/libs="$libs -lmysqlclient -lssl -lcrypto"/g' /usr/local/mysql/bin/mysql_config