]> git.ipfire.org Git - thirdparty/psycopg.git/commitdiff
docs: extend `libpq` install instructions for cross-platform use
authorMáté Gyöngyösi <gyongyosimate1@gmail.com>
Fri, 15 Nov 2024 13:58:02 +0000 (14:58 +0100)
committerGitHub <noreply@github.com>
Fri, 15 Nov 2024 13:58:02 +0000 (13:58 +0000)
See #950.

README.rst

index 004f0d03994bc3de1c5803b6581f4c625aacb54f..68b4458595cfdd01bd266409002fb83ddb54e281 100644 (file)
@@ -17,16 +17,27 @@ For further information about installation please check `the documentation`__.
 .. __: https://www.psycopg.org/psycopg3/docs/basic/install.html
 
 
+.. _Hacking:
+
 Hacking
 -------
 
-In order to work on the Psycopg source code you need to have the ``libpq``
-PostgreSQL client library installed in the system. For instance, on Debian
-systems, you can obtain it by running::
+In order to work on the Psycopg source code, you must have the
+``libpq`` PostgreSQL client library installed on the system. For instance, on
+Debian systems, you can obtain it by running::
 
     sudo apt install libpq5
 
-After which you can clone this repository::
+On macOS, run::
+
+    brew install libpq
+
+On Windows you can use EnterpriseDB's `installers`__ to obtain ``libpq``
+which is included in the Command Line Tools.
+
+.. __: https://www.enterprisedb.com/downloads/postgres-postgresql-downloads
+
+You can then clone this repository to develop Psycopg::
 
     git clone https://github.com/psycopg/psycopg.git
     cd psycopg
@@ -72,3 +83,13 @@ Now hack away! You can run the tests using::
     psql -c 'create database psycopg_test'
     export PSYCOPG_TEST_DSN="dbname=psycopg_test"
     pytest
+
+
+Cross-compiling
+---------------
+
+To use cross-platform zipapps created with `shiv`__ that include Psycopg
+as a dependency you must also have ``libpq`` installed. See
+`the section above <Hacking_>`_ for install instructions.
+
+.. __: https://github.com/linkedin/shiv