[Lazarus] PostgreSQL Questions

Marco van de Voort marcov at stack.nl
Mon Dec 5 09:58:14 CET 2011


On Sat, Dec 03, 2011 at 03:59:51PM -0500, Tom Russell wrote:
> I know there was a patch for the postgres unit in fpc so that the
> const set for the libpq stuff was not hard coded but I do not
> understand how the unit(s) find the path to which the libpq resides?

Afaik already 2.4.4 allows to override the lib location and name in the main
program
 
> I don't understand at least on OSX how I have to set a sym link for
> the file in Usr/Lib for the db connection to work.

Afaik a built in name is passed to the dlload OS call. For the rest it
follows normal OS rules.

> What if a developer had only access to the db on a server somewhere? 

That would be the server part of the DB. The library above is the client
part, and must run always on the system of the client application.

> Would you still need the libpq file just to develop?  And what about
> distributing your app afterwards, what do you have to supply with it in
> order for it to actually work?

Yes. There are some ways to integrate the library into the main program, but
while that eases installation somewhat, it makes the installation highly
rigid, and a minor database library update needs a new build.




More information about the Lazarus mailing list