Start by installing the required packages to compile
yum groupinstall 'Development Tools'
yum install php-devel
wget http://xcache.lighttpd.net/pub/Releases/1.3.2/xcache-1.3.2.tar.gz
tar zxfv xcache-1.3.2.tar.gz
cd xcache-1.3.2
phpize
./configure --enable-xcache
make
make install
After the last step take note of the reported path where the libraries were installed
Similar to :
/usr/lib64/php/modules/
Then we copy the configuration to the php.d include directory
cp xcache.ini /etc/php.d/
Lastly we edit the xcache.ini and fix the path in
extension = /usr/lib64/php/modules/xcache.so
Finaly restart your apache/lighttpd and you are ready.