If you are getting this error while trying to install Microsoft Drivers for PHP for SQL server
sudo pecl install sqlsrv sudo pecl install pdo_sqlsrv
you should do the following:
First:
Inspect this folder /usr/lib/x86_64-linux-gnu/ and verify that the following file exists: libltdl.la
Second:
If the file does not exist, just run the following command to create a blank file:
touch /usr/lib/x86_64-linux-gnu/libltdl.la
Try to run the pecl command again
sudo pecl install sqlsrv sudo pecl install pdo_sqlsrv
Third:
If the issue still persists, create a new file and copy the following content to it:
https://www.apt-browse.org/browse/debian/jessie/main/amd64/libltdl-dev/2.4.2-1.11+b1/file/usr/lib/x86_64-linux-gnu/libltdl.la
and try to install the sqlsrv and pdo_sqlsrv again.
then verify that you can see the pdo_sqlsrv module by running:
php -m
Reference
Linux and macOS Installation Tutorial for the Microsoft Drivers for PHP for SQL Server
2 comments Write a comment