I tried also an alternative configuration for nginx

Additional libraries are needed:

GD lib on Raspberry Pi via this article
sudo apt-get install libgd2-noxpm-dev

GeoIP 1.4.5 via this article
wget http://geolite.maxmind.com/download/geoip/api/c/GeoIP-1.4.5.tar.gz
tar -xvf GeoIP-1.4.5.tar.gz
./configure
make
make check
make install

And the nginx config command:
./configure --user=nginx --group=nginx --prefix=/etc/nginx --sbin-path=/usr/sbin/nginx --conf-path=/etc/nginx/nginx.conf --pid-path=/var/run/nginx.pid --lock-path=/var/run/nginx.lock --error-log-path=/var/log/nginx/error.log --http-log-path=/var/log/nginx/access.log --with-http_gunzip_module --with-http_secure_link_module --with-http_auth_request_module --with-http_gzip_static_module --with-http_stub_status_module --with-http_ssl_module --with-pcre --with-file-aio --with-http_realip_module --with-stream --with-stream_ssl_module --with-debug --with-http_flv_module --with-http_mp4_module --with-http_dav_module --with-http_sub_module --with-http_geoip_module --with-http_addition_module --with-http_v2_module --with-http_image_filter_module --with-http_degradation_module --without-http_scgi_module --without-http_uwsgi_module