John R Pierce wrote: >> I am new to the product and in windows “postgres.lib” provides certain functions which we are >> using in windows for creating extensions. >> >> Now I am porting the project to Linux and there no straight library with this name in Linux >> binaries packages. >> >> Can someone please advise the equivalent library for postgres.lib in Linux? > > I am not sure what this postgres.lib is, what are the functions you're using ? With MSVC, you have to link with the mylibrary.lib file if you want to use functions from the shared library mylibrary.dll. This is not necessary on Linux, where references to a shared library are resolved at load time. So the answer to the original question is that there is no replacement for postgres.lib on Linux because you don't need it to link with PostgreSQL. It is enough to #include the required PostgreSQL headers during compilation. Some information on how to link on Linux can be found here: https://www.postgresql.org/docs/current/static/xfunc-c.html#DFUNC But as others have remarked, using PGXS is much better than doing it by hand. Yours, Laurenz Albe -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general