phpsolarissolaris-10

PHP Fail on solaris 10


I'm trying to get PHP to work on a Solaris 10 machine, PHP was installed successfully without throwing any errors using the below configuration:

./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/lib --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql --with-mysqli --with-pdo-mysql --with-mssql=/usr/local/freetds --without-pgsql --with-zlib --with-zlib-dir=/usr/local --with-iconv-dir=/usr/local --with-pcre-dir=/usr/local --with-gettext=/usr/local --with-libxml-dir=/usr/local --with-gd --with-xpm-dir=/usr/local --with-jpeg-dir=/usr/local --with-png-dir=/usr/local --with-gnu-ld --enable-shared --enable-mbstring --enable-exif --enable-soap --enable-zip --enable-ftp --enable-mysqlnd --disable-zend-signals --disable-static

However when I start my Apache server, and accessing php info page:

<?php

// Show all information, defaults to INFO_ALL
phpinfo();

?>

I get a blank page..

when running php -m , i get a lot of fatal errors about many failing libraries, below is the output:

[root@mm]#php -m
ld.so.1: php: fatal: libreadline.so.6: open failed: No such file or directory
ld.so.1: php: fatal: libmysqlclient.so.18: open failed: No such file or directory
ld.so.1: php: fatal: libsybdb.so.5: open failed: No such file or directory
ld.so.1: php: fatal: libmcrypt.so.4: open failed: No such file or directory
ld.so.1: php: fatal: libltdl.so.7: open failed: No such file or directory
ld.so.1: php: fatal: /usr/sfw/lib/amd64//libfreetype.so.6: wrong ELF class: ELFCLASS64
ld.so.1: php: fatal: libX11.so.6: open failed: No such file or directory
ld.so.1: php: fatal: libxcb.so.1: open failed: No such file or directory
ld.so.1: php: fatal: libXau.so.6: open failed: No such file or directory
ld.so.1: php: fatal: libXdmcp.so.6: open failed: No such file or directory
ld.so.1: php: fatal: libpng14.so.14: open failed: No such file or directory
ld.so.1: php: fatal: libjpeg.so.8: open failed: No such file or directory
ld.so.1: php: fatal: libdb-4.8.so: open failed: No such file or directory
ld.so.1: php: fatal: libgdbm.so.3: open failed: No such file or directory
ld.so.1: php: fatal: libpcre.so.1: open failed: No such file or directory
ld.so.1: php: fatal: libcrypto.so.0.9.8: open failed: No such file or directory
ld.so.1: php: fatal: libssl.so.0.9.8: open failed: No such file or directory
ld.so.1: php: fatal: libgssapi_krb5.so.2: open failed: No such file or directory
ld.so.1: php: fatal: libkrb5.so.3: open failed: No such file or directory
ld.so.1: php: fatal: libk5crypto.so.3: open failed: No such file or directory
ld.so.1: php: fatal: libcom_err.so.3: open failed: No such file or directory
ld.so.1: php: fatal: libcurl.so.4: open failed: No such file or directory
ld.so.1: php: fatal: libldap-2.4.so.2: open failed: No such file or directory
ld.so.1: php: fatal: liblber-2.4.so.2: open failed: No such file or directory
ld.so.1: php: fatal: libintl.so.8: open failed: No such file or directory
ld.so.1: php: fatal: libsasl2.so.2: open failed: No such file or directory
ld.so.1: php: fatal: libssh2.so.1: open failed: No such file or directory
ld.so.1: php: fatal: libiodbc.so.2: open failed: No such file or directory
ld.so.1: php: fatal: libiconv.so.2: open failed: No such file or directory
ld.so.1: php: fatal: relocation error: file /usr/local/bin/php: symbol rl_library_version: referenced symbol not found
Killed

Thnaks


Solution

  • thanks for the helpful information, i managed to resolve the issue by adding:

    LoadModule php7_module        modules/libphp7.so
    AddType application/x-httpd-php .php
    AddType application/x-httpd-php-source .phps
    PHPIniDir "/usr/local/php/etc/" //this is the location of the PHP configurations file
    

    to the Apache configuration file, then restarting the Apache server..