Se você precisar do imap compilado no php, execute estes comandos:
yum install -y pam-devel libc-client libc-client-devel
cd /usr/local/directadmin/custombuild
./build update
./build set_php imap yes
./build php_imap