Having installed CentOS (wikipedia) on a server here, I was surprised to find that, by default, the source repositories were not enabled.
Below are the source repo definitions I use.  Simply create a file called “Centos-Source.repo” (# chmod 644) in /etc/yum.repos.d/ and enable repositories as required (using enabled=1).  Please note that this example is for CentOS version 5 and may differ from any official versions out there.  I offer no warranty… it just works for me. ;-)

[base-SRPMS]
name=CentOS-$releasever – Base SRPMS
baseurl=http://mirror.centos.org/centos/$releasever/os/SRPMS/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=1
enabled=1
#released updates
[update-SRPMS]
name=CentOS-$releasever – Updates SRPMS
baseurl=http://mirror.centos.org/centos/$releasever/updates/SRPMS/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=1
enabled=1
#packages used/produced in the build but not released
[addons-SRPMS]
name=CentOS-$releasever – Addons SRPMS
baseurl=http://mirror.centos.org/centos/$releasever/addons/SRPMS/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=1
enabled=0
#additional packages that may be useful
[extras-SRPMS]
name=CentOS-$releasever – Extras SRPMS
baseurl=http://mirror.centos.org/centos/$releasever/extras/SRPMS/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=1
enabled=0
#additional packages that extend functionality of existing packages
[centosplus-SRPMS]
name=CentOS-$releasever – Plus SRPMS
baseurl=http://mirror.centos.org/centos/$releasever/centosplus/SRPMS/
gpgcheck=1
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=1
#contrib – packages by Centos Users
[contrib-SRPMS]
name=CentOS-$releasever – Contrib SRPMS
baseurl=http://mirror.centos.org/centos/$releasever/contrib/SRPMS/
gpgcheck=1
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5
priority=1

Have your say!