Build oci for PHP

mount DVD iso

vi /etc/yum.repos.d/CentOS-Media.repo

 add file:///media/xxx   corresponding to the DVD media

download php source

yum –enablerepo=c6-media install libxml-devel

yum –enablerepo=c6-media install httpd-devel

extract php sources

./confgure

make
make test
make install

Download Oracle Client & SDK

vi /etc/ld.so.conf.d/oracle-11g-64.conf
/opt/app/oracle/product/11.2.0

export ORACLE_HOME=/opt/app/oracle/product/11.2.0
ln -s libclntsh.so.11.1 libclntsh.so

/usr/sbin/setenforce 0     ??

export CFLAGS=-m64
export CPPFLAGS=-m64
export CCASFLAGS=-m64

cd php sources
cd ext
cd oci8
phpize
./configure –with-oci8=instantclient,/opt/app/oracle/product/11.2.0,11.2.0.3.0
make
ls modules

cd php sources
cd ext
cd pdo_oci
phpize
./configure –with-pdo-oci=shared,instantclient,/opt/app/oracle/product/11.2.0,11.2.0.3.0
make
ls modules