Re: c program fails to run with the postgres which is installed at user location

Поиск
Список
Период
Сортировка
От John R Pierce
Тема Re: c program fails to run with the postgres which is installed at user location
Дата
Msg-id 4C07489C.1040600@hogranch.com
обсуждение исходный текст
Ответ на c program fails to run with the postgres which is installed at user location  (zhong ming wu <mr.z.m.wu@gmail.com>)
Ответы Re: c program fails to run with the postgres which is installed at user location  (zhong ming wu <mr.z.m.wu@gmail.com>)
Список pgsql-general
zhong ming wu wrote:
> ...
> This machine is RHEL 5.5 and has both RH stock postgres 8.1.18 in
> standard location as well as pg 8.4.4
> which is in my home folder.   The libraries are libpg.so.4 and
> libpg.so.5 respectively for two versions.
>
> I just lifted one of the examples from postgres documentation and if I
> just use stock 8.1.18 compiling
> is ok and the final program runs to completion as expected.  But if I
> compile the same program
> with 8.4.4 the compiled program dies with
>
> "error while loading shared libraries: libpq.so.5: cannot open shared
> object file: No such file or dire
> ctory"
>
> Does the error mean that the program can't locate this libpq.so.5?
> That symlink is good but in ~/local/lib and points to
> libpq.so.5.2 in there.  It's not in the standard folder like /usr/lib.
>  I tried to symlink to the working folder but no go.
>

you probably need to either use "-R $HOME/local/lib" on the link command
to specify the runtime path to find .so's in, or add $HOME/local/lib to
LD_LIBRARY_PATH (I prefer the former if the linking is under my control,
but revert to the latter if I absolutely have to)



В списке pgsql-general по дате отправления:

Предыдущее
От: Bryan Montgomery
Дата:
Сообщение: Attempting to get kerberos authentication working
Следующее
От: Len Walter
Дата:
Сообщение: Re: Commit every N rows in PL/pgsql