You first have to install the devel packages for unixodbc, then add a line in rawopts file and rebuild Apache+PHP.
1. Install the UnixODBC devel packages:
yum install unixODBC unixODBC-devel
2. You now need to create a file “all_php5″ to add a line to enable odbc so that apache build will pick it up from there. File all_php5 is for PHP5 and all_php4 is for PHP4.
pico /var/cpanel/easy/apache/rawopts/all_php5
3. Add the following line:
–with-unixODBC=/usr
4. Rebuild Apache/PHP using the “easyapache” script and the above file will be picked up automatically:
/scripts/easyapache
Once the compilation completes, you should have odbc module compiled with PHP. You can check the module either using a phpinfo() file OR through shell by executing:
