>> Hi all,
>>
>> After several attempts, I am asking for help with how to compile libpq with OpenSSL
>> statically linked.
>> I need to have libpq linked with LibreSSL, but if I could statically link OpenSSL, I think
>> I could switch the TLS libraries at compile time.
>
> redo the step which creates libpq.so appending your libssl.a location
> (mine is /usr/lib/x86_64-linux-gnu/libssl.a) at the end.
Just wanted to correct: you also have to remove "-lssl". So I guess you can just
substitute "-lssl" for libssl.a location in src/interfaces/libpq/Makefile (two occurrences)
and build as usual.