GCC-4.2 error on Mac OSX Mountain Lion, unable to install mysql-python

后端 未结 4 1103
说谎
说谎 2020-12-25 09:04

I\'m having trouble building MySQLdb on Mac OSX Mountain Lion. After upgrading to OSX Mountain Lion from OSX Lion, I have downloaded and installed Xcode 4.4 also. Then, I we

4条回答
  •  自闭症患者
    2020-12-25 09:27

    I ran into this. For me it was because I installed python from a DMG installer at http://python.org . Those are built against the wrong gcc. I fixed it by compiling python from source using Homebrew: http://mxcl.github.com/homebrew/

    brew install python
    

    That links against the correct gcc

    (In my specific case I was using an older Python which is why I had used a DMG installer. I discovered that homebrew also has formulas for older versions)

提交回复
热议问题