Re: Interface to posgresql - Mailing list pgsql-general

From Shane Ambler
Subject Re: Interface to posgresql
Date
Msg-id 45E9545B.9000309@Sheeky.Biz
Whole thread Raw
In response to Interface to posgresql  (makhan <emoazzam@yahoo.com>)
List pgsql-general
makhan wrote:
> Hi
>
> I am trying to connect to the postgresql and make quries usuing my
> application in c language using the libpq library.can you please tell me how
> to setup the enviromnet and where to place files so that I can run examples
> given on the libpq site.( if I use gcc compiler on linux or borland turbo c)
>
> Regards
The standard placing for the files is /usr/lib for libpq and
/usr/include for the header files.

These paths should be standard search paths for gcc

I believe the linux installs have these files as part of the devel
install - the postgresql-devel-xxx rpm - you will need to install that.

If you have done a manual setup and build from source then /usr would be
replaced with the prefix path used (./configure --prefix=...)
eg. /usr/local/pgsql/lib is a common one.

For gcc HEADER_SEARCH_PATHS is used for headers and LIBRARY_SEARCH_PATHS
for libs. Or -I can be used as an option to gcc and -L with ld when
linking. eg gcc -I /usr/local/pgsql/include myprog.c

--

Shane Ambler
pgSQL@Sheeky.Biz

Get Sheeky @ http://Sheeky.Biz

pgsql-general by date:

Previous
From: makhan
Date:
Subject: Interface to posgresql
Next
From: Hannes Dorbath
Date:
Subject: Re: I'd love to know what the rest of this error message is.