How to build 64-bit Python on OS X 10.6 — ONLY 64 bit, no Universal nonsense

后端 未结 4 1866
旧时难觅i
旧时难觅i 2021-01-12 15:02

I just want to build this on my development machine -- the binary install from Python.org is still 32 bits and installing extensions (MySQLdb, for example) is driving me nut

4条回答
  •  我在风中等你
    2021-01-12 15:47

    Always macports... sheesh

    This is what I did:

    ~: wget http://python.org/ftp/python/2.6.5/Python-2.6.5.tar.bz2
    ~: tar xjf Python-2.6.5.tar.bz2
    ~: cd Python-2.6.5
    ~: ./configure ./configure MACOSX_DEPLOYMENT_TARGET=10.6 --enable-framework --with-universal-archs="64-bit" CFLAGS="-arch x86_64" LDFLAGS="-arch x86_64"
    ~: make -j6
    ~: sudo make install
    

    Might be a little redundant on the FLAGS stuff, but it worked.

提交回复
热议问题