I remember that there were some issues, but unfortunately I didn't document how I resolved them :(
Juan Pablo 2009/7/14 Kevin <hekevint...@gmail.com>: > > Thanks a lot Juan! It works fine on my machine. Would you be able to > share your compilation steps? > > On Jul 14, 7:32 am, Juan Pablo Romero Méndez <jpablo.rom...@gmail.com> > wrote: >> I don't know if it will run in your machine, but here is one compiled >> for Python2.5, MacOS X 10.5.7, and PostgreSQL 8.3. >> >> Regards, >> >> Juan Pablo >> >> 2009/7/14 Kevin <hekevint...@gmail.com>: >> >> >> >> >> >> > I need to get psycopg2 installed on Mac OS X 10.5 >> >> > I have read every install guide I could find and I still do not have >> > it working. I have developer tools installed. I am running MacPython >> > 2.6.2 and PostgreSQL 8.4 downloaded >> > fromhttp://www.enterprisedb.com/products/pgdownload.do >> >> > On my production machine (Debian) I did a simple atp-get and it >> > worked. Why is it so much harder on Mac OS X? I am very near ripping >> > my hair out because I have wasted too much time and I do not >> > understand why psycopg2 does not work on my machine. >> >> > Below are my notes from three attempts to install psycopg2. I have >> > read other threads that suggest installing Python, PostgreSQL, and >> > psycopg2 from MacPorts. I do not want to use MacPorts. I do not see >> > why I need to use a completely different installation of Python to use >> > a simple database driver. >> >> > For my first attempt I followed the instructions listed here: >> >http://jasonism.org/weblog/2008/nov/06/getting-psycopg2-work-mac-os-x... >> > It told me to add these lines to setup.cfg: >> >> > include_dirs=/Library/PostgreSQL/8.3/include >> > library_dirs=/Library/PostgreSQL/8.3/lib >> >> > I then ran python setup.py build and got this error: >> >> > $ python setup.py build >> > running build >> > running build_py >> > creating build >> > creating build/lib.macosx-10.3-fat-2.6 >> > creating build/lib.macosx-10.3-fat-2.6/psycopg2 >> > copying lib/__init__.py -> build/lib.macosx-10.3-fat-2.6/psycopg2 >> > copying lib/errorcodes.py -> build/lib.macosx-10.3-fat-2.6/psycopg2 >> > copying lib/extensions.py -> build/lib.macosx-10.3-fat-2.6/psycopg2 >> > copying lib/extras.py -> build/lib.macosx-10.3-fat-2.6/psycopg2 >> > copying lib/pool.py -> build/lib.macosx-10.3-fat-2.6/psycopg2 >> > copying lib/psycopg1.py -> build/lib.macosx-10.3-fat-2.6/psycopg2 >> > copying lib/tz.py -> build/lib.macosx-10.3-fat-2.6/psycopg2 >> > running build_ext >> > error: No such file or directory >> >> > =================================================== >> >> > For my next attempt I followed the instructions listed here: >> >http://blog.jonypawks.net/2008/06/20/installing-psycopg2-on-os-x/ >> > It told me to run this: >> >> > PATH=$PATH:/Library/PostgresPlus/8.3/bin/ sudo easy_install psycopg2 >> >> > This resulted in this error: (I substituted "8.4" for "8.3" because my >> > version of PostgreSQL is newer) >> >> > $ PATH=$PATH:/Library/PostgreSQL/8.4/bin/ sudo easy_install psycopg2 >> > Password: >> > Searching for psycopg2 >> > Readinghttp://pypi.python.org/simple/psycopg2/ >> > Readinghttp://initd.org/projects/psycopg2 >> > Readinghttp://initd.org/pub/software/psycopg/ >> > Best match: psycopg2 2.0.11 >> > Downloadinghttp://initd.org/pub/software/psycopg/psycopg2-2.0.11.tar.gz >> > Processing psycopg2-2.0.11.tar.gz >> > Running psycopg2-2.0.11/setup.py -q bdist_egg --dist-dir /tmp/ >> > easy_install-dUXtsI/psycopg2-2.0.11/egg-dist-tmp-1008XV >> > warning: no files found matching '*.html' under directory 'doc' >> > warning: no files found matching 'MANIFEST' >> > /usr/libexec/gcc/i686-apple-darwin9/4.0.1/as: assembler (/usr/bin/../ >> > libexec/gcc/darwin/i386/as or /usr/bin/../local/libexec/gcc/darwin/ >> > i386/as) for architecture i386 not installed >> > /usr/libexec/gcc/powerpc-apple-darwin9/4.0.1/as: assembler (/usr/ >> > bin/../libexec/gcc/darwin/ppc/as or /usr/bin/../local/libexec/gcc/ >> > darwin/ppc/as) for architecture ppc not installed >> > Installed assemblers are: >> > /usr/bin/../libexec/gcc/darwin/ppc64/as for architecture ppc64 >> > /usr/bin/../libexec/gcc/darwin/x86_64/as for architecture x86_64 >> > Installed assemblers are: >> > /usr/bin/../libexec/gcc/darwin/ppc64/as for architecture ppc64 >> > /usr/bin/../libexec/gcc/darwin/x86_64/as for architecture x86_64 >> > lipo: can't open input file: /var/tmp//ccSK6sd7.out (No such file or >> > directory) >> > error: Setup script exited with error: command 'gcc' failed with exit >> > status 1 >> > Exception TypeError: TypeError("'NoneType' object is not callable",) >> > in <bound method Popen.__del__ of <subprocess.Popen object at >> > 0x9e3910>> ignored >> > Exception TypeError: TypeError("'NoneType' object is not callable",) >> > in <bound method Popen.__del__ of <subprocess.Popen object at >> > 0x9e3970>> ignored >> >> > =================================================== >> >> > For my third attempt I installed the binary of psycopg2 from >> >http://pythonmac.org/packages/py25-fat/index.html >> > I thought it worked, but when I tried to import the module in the >> > interpreter I got this error: >> >> >>>> import psycopg2 >> > Traceback (most recent call last): >> > File "<stdin>", line 1, in <module> >> > File "/Library/Frameworks/Python.framework/Versions/2.6/lib/ >> > python2.6/site-packages/psycopg2/__init__.py", line 60, in <module> >> > from _psycopg import BINARY, NUMBER, STRING, DATETIME, ROWID >> > ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.6/ >> > lib/python2.6/site-packages/psycopg2/_psycopg.so, 2): Library not >> > loaded: /usr/local/pgsql/lib/libpq.4.dylib >> > Referenced from: /Library/Frameworks/Python.framework/Versions/2.6/ >> > lib/python2.6/site-packages/psycopg2/_psycopg.so >> > Reason: image not found >> >> > What the hell do I need to do to get psycopg2 working with my >> > MacPython 2.6.2 install? Sorry if I sound angry, but I have lost a >> > lot of time on something that seems like it should be easy. >> >> >> >> psycopg2.tar.gz >> 155KViewDownload > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---