Daniele (namesake),
Thanks for the quick response. I tried that, it looks like
https://github.com/psycopg/psycopg2/blob/master/scripts/build/appveyor.py#L291
shows the build step:
python setup.py build_ext -l "libpgcommon libpgport"
After that, I still get a binary that depends on libpq.dll - b
On Tue, 5 Oct 2021 at 00:30, Dan Davis wrote:
>
> Can anyone give me a solution to build psycopg2 statically on Windows?
You can follow what Appveyor does, which is the CI that builds
psycopg2 packages.
- this is the setup
https://github.com/psycopg/psycopg2/blob/master/.appveyor/packages.yml
-
Can anyone give me a solution to build psycopg2 statically on Windows?
I have succeeded in building it, but when I run dumpbin /dependents on the
generated file (the PYD file), it still depends on libpq.dll even when I
pass --static-libpq.
*Environment*
- OS: Windows 10
- Psycopg version: psycop