Library Problem Calling External Program from PHP

Problems with the Linux version of XAMPP, questions, comments, and anything related.

Library Problem Calling External Program from PHP

Postby mikedombo » 04. February 2018 04:23

Hi,
I'm using XAMPP 7.2.1 x64 on Ubuntu Server 17.10 x64. I'm trying to migrate my website from xampp on Windows.

I am getting the following message "node: /opt/lampp/lib/libssl.so.1.0.0: version `OPENSSL_1.0.1' not found (required by node) node: /opt/lampp/lib/libcrypto.so.1.0.0: version `OPENSSL_1.0.1d' not found (required by node)" when calling "node --version" from php using shell_exec.

I had a previous error about libstdc++ which I was able to fix by copying that library from my /usr/lib into the /opt/lampp/lib. That worked with no issues, but when I do that with libssl and libcrypto the error message goes away, but xampp can no longer start.

I need a way to replace the /opt/lampp/lib libraries with updated versions or a way to get shell_exec in php to use the system libraries. The path LD_LIBRARY_PATH is set by xampp to /opt/lampp/lib, but I cannot find a way to disable this.

Any help would be appreciated, thanks!
mikedombo
 
Posts: 2
Joined: 04. February 2018 04:18
XAMPP version: 7.2.1
Operating System: Ubuntu Server 17.10

Re: Library Problem Calling External Program from PHP

Postby Nobbie » 04. February 2018 10:44

The LD_LIBRARY_PATH and quite a lot more environment is setup in the startup shell script "xampp" (where "lampp" is a symbolic link to "xampp"). You may edit /opt/lampp/xampp and modify it to your needs.
Nobbie
 
Posts: 9991
Joined: 09. March 2008 13:04

Re: Library Problem Calling External Program from PHP

Postby mikedombo » 04. February 2018 14:03

I did try to edit the startup script, however the LD_LIBRARY_PATH was still set to /opt/lampp/lib even after restarting the server. I first edited it to add /usr/lib before it put in the xampp libraries and I then tried commenting out all the times it "exports" LD_LIBRARY_PATH, and again this did not work.
mikedombo
 
Posts: 2
Joined: 04. February 2018 04:18
XAMPP version: 7.2.1
Operating System: Ubuntu Server 17.10

Re: Library Problem Calling External Program from PHP

Postby Nobbie » 04. February 2018 22:43

mikedombo wrote:I did try to edit the startup script, however the LD_LIBRARY_PATH was still set to /opt/lampp/lib even after restarting the server. I first edited it to add /usr/lib before it put in the xampp libraries and I then tried commenting out all the times it "exports" LD_LIBRARY_PATH, and again this did not work.


For test reason, i simply started httpd plainly, opened a terminal, cd into /opt/lampp/bin and started httpd directly via "sudo ./httpd". I loaded localhost into the browser and did run a phpinfo(). In the environment section was no LD_LIBRARY_PATH. Everything as expected.
Nobbie
 
Posts: 9991
Joined: 09. March 2008 13:04


Return to XAMPP for Linux

Who is online

Users browsing this forum: No registered users and 3 guests