Ok, got to it like this:
First I had to get my php on MAMP to be configured with the appropriate php source which does not ship with MAMP
- I changed to the latest PHP version on MAMP, for me 5.6.10, also changed my PATH variables to the new bin for php:
/Applications/MAMP/bin/php/php5.6.10/bin/
- Downloaded the php 5.6.10 source, extracted it and renamed the folder to just ‘
php
’
- Navigated to
/Applications/MAMP/bin/php/php5.6.10
and created a directory called ‘include
’ - copied the downloaded php
folder in there
- cd
/Applications/MAMP/bin/php/php5.6.10/include/php
and ran ./configure
Then followed the instructions here: https://github.com/datastax/php-driver/blob/master/ext/README.md
- In terminal, ran:
brew install libuv cmake gmp
- In a directory where in makes sense, run :
git clone https://github.com/datastax/php-driver.git
cd php-driver
git submodule update --init
cd ext
./install.sh
phpize
./configure
make install
Then edited the php.ini to add in: extension=cassandra.so