I have a linking problem
error message:
/usr/local/bin/gecods: error while loading shared libraries: libpq++.so.4: cannot open shared object file: No such file or directory
===
I compiled a simple program called gecods, it dynamically links to libpq++.so.4 in
/usr/local/pgsql/lib/ (a postgres database C++ interface)
I can run gecods program with no problem with me as user. My modperl perl program is a simple test program:
It simply calls the C++ program, gecods and capture the output
$result=`/usr/local/bin/gecods -f $inputfile`;
This works in a normal shell enviroment. But when I run this under mod_perl it cannot find the
libpq++.so.4
I tried to make a copy of libpq++.so.4 in /usr/local/apache2/lib This did not fix the problem I made another copy to /usr/local/lib It did not fix the problem either.
During the compilation of my simple program gecods my linking dir is set $LD_LIBRARY_PATH=/usr/local/pgsql/lib
Kemin, try to add:
PassEnv LD_LIBRARY_PATH
to your httpd.conf. Normally environment from the shell is not copied into Apache runtime. You need to explicitly specify the variables to make available to programs running under mod_perl.
If you need this before the response phase, use PerlPassEnv instead: http://perl.apache.org/docs/1.0/guide/config.html#PerlSetEnv_and_PerlPassEnv
-- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
-- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html