public inbox for [email protected]
help / color / mirror / Atom feedFrom: Tony Wayne <[email protected]>
To: [email protected]
Subject: Cant link libpq with a pg extension using cmake
Date: Mon, 1 Apr 2024 06:17:33 +0530
Message-ID: <CAAW5B8zyBjeV02yiWeu3iX7=CJfJDybTnmpP88DPaWMtcqpiPw@mail.gmail.com> (raw)
i am getting linking issues when trying to link libpq with my pg extension
and i am using pg's libpq ,so libpq is built along with pg,so i did this in
my extension's cmakelists.txt
file (GLOB storage_SRC CONFIGURE_DEPENDS "*.cpp" )
add_library(storage OBJECT ${storage_SRC})
target_link_libraries(storage PRIVATE pq)
btw included all required include dirs in my toplevel cmakelists.txt
then i got undefined symbol: pqsecure_write but don't know why if i give
the pg_config --libdir/libpq.a path in target_link_libraries instead of lib
name then it links but walreceiver process cant start and i get FATAL:
could not connect to the primary server: libpq is incorrectly linked to
backend functions
view thread (2+ messages)
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected]
Subject: Re: Cant link libpq with a pg extension using cmake
In-Reply-To: <CAAW5B8zyBjeV02yiWeu3iX7=CJfJDybTnmpP88DPaWMtcqpiPw@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox