Installing the GD library is easy on CentOS thanks to yum.
Simply type the following command and all your GD fun is installed and ready to go
yum install gd gd-devel php-gd