必要なライブラリ

SQLObject

Mac OS X でのインストールは以下のコマンド一発

$ sudo easy_install -U SQLObject

MySQL for Python

Mac OS X で MySQL for Python を build すると

In file included from /usr/local/mysql/include/mysql.h:47,
                 from _mysql.c:40:
/usr/include/sys/types.h:92: error: duplicate ‘unsigned’
/usr/include/sys/types.h:92: error: two or more data types in declaration specifiers
error: command 'gcc' failed with exit status 1

といったエラーが発生する。
_mysql.c の 37-39行の以下をコメントアウトしてからbuildすればOK。

//#ifndef uint
//#define uint unsigned int
//#endif

参考:How to install Django with MySQL on Mac OS X

MySQLdb


トップ   編集 凍結 差分 バックアップ 添付 複製 名前変更 リロード   新規 一覧 単語検索 最終更新   ヘルプ   最終更新のRSS
Last-modified: 2017-04-09 (日) 21:28:04 (2579d)