Php pecl config error on centos

When installing php PECL On CentOS/RHEL (+cPanel) installations, if you get a “checking whether the C compiler works… configure: error: cannot run C compiled programs”, you may need to remount the /tmp and /var/tmp with exec permissions first:

$ mount -o remount,exec,suid /tmp
$ mount -o remount,exec,suid /var/tmp

Then:

$ pecl install {package}

And, don’t forget to remount them as noexec after.

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *