This project is archived and is in readonly mode.

#47 ✓resolved
Matthew Ryan

Can only specify static-libpq in setup.cfg

Reported by Matthew Ryan | March 9th, 2011 @ 04:57 PM

This is extant in the current 2.4 release.

The current setup.py only allows setting the static-libpq option
via the setup.cfg, and doesn't accept it on the setup.py commandline.
Instead, you get the following error:
error: error in command line: command 'psycopg_build_ext' has no such option 'static_libpq'

I've attached a minimal patch which makes it work, tested on RHEL-5 and OSX.

Comments and changes to this ticket

  • Daniele Varrazzo

    Daniele Varrazzo March 16th, 2011 @ 12:07 PM

    • Tag set to patch, setup
    • State changed from “new” to “open”

    Thanks, I think there is no problem in merging the patch.

  • Daniele Varrazzo

    Daniele Varrazzo March 26th, 2011 @ 01:42 PM

    • State changed from “open” to “resolved”

    I'm merging the patch. However for me (on ubuntu) the compiled library doesn't work:

    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/home/piro/dev/psycopg2/build/lib.2.6/psycopg2/__init__.py", line 71, in <module>
        from psycopg2._psycopg import BINARY, NUMBER, STRING, DATETIME, ROWID
    ImportError: /home/piro/dev/psycopg2/build/lib.2.6/psycopg2/_psycopg.so: undefined symbol: GSS_C_NT_HOSTBASED_SERVICE
    make: *** [check] Error 1
    

    I suspect what is missing is linking against the crypto libraries. The problem is not in the patch anyway: you get the same setting static_libpq in setup.cfg. So I'll leave people who know what to do (which is not me) solving the problem specifying --libraries too.

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

<b>WARNING:</b> the informations in this tracker are archived. Please submit new tickets or comments to <a href="https://github.com/psycopg/psycopg2/issues">the new tracker</a>.
<br/>
Psycopg is the most used PostgreSQL adapter for the Python programming language. At the core it fully implements the Python DB API 2.0 specifications. Several extensions allow access to many of the features offered by PostgreSQL.

Shared Ticket Bins

People watching this ticket

Attachments

Tags

Pages