|
From: Hans-Bernhard B. <HBB...@t-...> - 2009-07-09 20:30:07
|
Andrew Shanks wrote: > from the terminal, I am able to create the graph, but when I run the script > from a web application running on an apache http server 2.2 (on the same > machine), I see the error message "gnuplot: error while loading shared > libraries: libgd.so.2: cannot open shared object file: No such file or > directory". That's because your web server (for good reasons) runs subprocesses in an environment configured considerably more restrictively than a logged-in user's interactive shell. Apparently one such restriction applies to the LD_LIBRARY_PATH. > I've installed gnuplot 4.2, gd-2.0.35, libpng-1.2.37, > zlib-1.2.3 and libjpeg-v7, but when I do slocate libgd, I can only find > /usr/lib/libgdm.so.2. I'm afraid you're asking the wrong tool. The libgd.so your gnuplot binary uses if you run it interactively would be found by asking the dynamic linker about it. On Linux, I think that's still done by ldd gnuplot |