Mod_cloudflare with Easyapache 4 and Apache 2.4 on CentOS 6.9

mod_cloudflare
apache

#1

Hi,

I have installed

After installation, Apache is unable to start, and fails with:
Starting httpd: httpd: Syntax error on line 236 of /etc/apache2/conf/httpd.conf: Syntax error on line 1 of /etc/apache2/conf.d/cloudflare.conf: Cannot load /usr/lib64/apache2/modules/mod_cloudflare.so into server: /usr/lib64/apache2/modules/mod_cloudflare.so: undefined symbol: ap_log_rerror

I tried running the options indicated here as well: https://www.cloudflare.com/technical-resources/#mod_cloudflare
but none seem to work.

I also tried to build manually with:

cd /tmp
wget https://www.cloudflare.com/static/misc/mod_cloudflare/mod_cloudflare.c
apxs -a -i -c mod_cloudflare.c

but that gives:
cannot open /usr/local/apache/build/config_vars.mk: No such file or directory at /usr/bin/apxs line 217.

Anyone that can help?

Thanks!!


#2

I found a solution :). You have to install ea-apache24-devel

So:
yum install ea-apache24-devel
cd /tmp
wget https://www.cloudflare.com/static/misc/mod_cloudflare/mod_cloudflare.c
apxs -a -i -c mod_cloudflare.c


#3

User555 solution worked like a charm. Thank you so much.