Upstream distributes psycopg-c with prebuilt binaries as psycopg-binar on PyPI. --- a/psycopg/setup.py +++ b/psycopg/setup.py @@ -29,7 +29,7 @@ extras_require = { ], # Install the stand-alone C extension module "binary": [ - f"psycopg-binary == {version}; implementation_name != 'pypy'", + f"psycopg-c == {version}; implementation_name != 'pypy'", # XXX-Patched ], # Install the connection pool "pool": [ --- a/psycopg/psycopg/_cmodule.py +++ b/psycopg/psycopg/_cmodule.py @@ -16,8 +16,8 @@ if pq.__impl__ == "c": from psycopg_c import _psycopg as _psycopg from psycopg_c import __version__ as __version__ # noqa: F401 elif pq.__impl__ == "binary": - from psycopg_binary import _psycopg as _psycopg # type: ignore - from psycopg_binary import __version__ as __version__ # type: ignore # noqa: F401 + from psycopg_c import _psycopg as _psycopg # type: ignore # XXX-Patched: s/_binary/_c/ + from psycopg_c import __version__ as __version__ # type: ignore # noqa: F401 # XXX-Patched: s/_binary/_c/ elif pq.__impl__ == "python": _psycopg = None # type: ignore else: