How To Install PHP GMP on Mac OSX 10.3.7

I wanted do some number crunching with the GNU MP Libarary on my Macbook, but it wasn't available by default.

Installation was pretty simple though.

1) Run php --version to check what version of PHP you have.

2) Download that version of PHP somewhere on your system.

3) phpize & compile it

# cd php-5.3.15/ext/gmp
# phpize
# ./configure
# make
# make install

4) Add the following to your php.ini

extension=gmp.so

5) Restart Apache