Nginx make error, when --with-http_perl_module

#./configure --user=elove --group=elove --prefix=/home/elove/app/nginx
–with-http_stub_status_module --with-http_ssl_module
–with-openssl=/home/elove/openssl-0.9.8c --with-http_perl_module
–with-perl=/usr/bin/perl
–with-perl_modules_path=/home/elove/app/nginx/modules/perl/

checking for OS

  • Linux 2.6.18-8.el5xen i686
    checking for C compiler … found
  • using GNU C compiler
  • gcc version: 4.1.1 20070105 (Red Hat 4.1.1-52)
    checking for gcc -pipe switch … found
    checking for gcc variadic macros … found
    checking for C99 variadic macros … found
    checking for unistd.h … found
    checking for inttypes.h … found
    checking for limits.h … found
    checking for sys/filio.h … not found
    checking for sys/param.h … found
    checking for sys/mount.h … found
    checking for sys/statvfs.h … found
    checking for crypt.h … found
    checking for Linux specific features
    checking for epoll … found
    checking for sendfile() … found
    checking for sendfile64() … found
    checking for sys/prctl.h … found
    checking for prctl(PR_SET_DUMPABLE) … found
    checking for sched_setaffinity() … found
    checking for crypt_r() … found
    checking for sys/vfs.h … found
    checking for poll() … found
    checking for /dev/poll … not found
    checking for kqueue … not found
    checking for crypt() … not found
    checking for crypt() in libcrypt … found
    checking for O_DIRECT … found
    checking for F_NOCACHE … not found
    checking for directio() … not found
    checking for statfs() … found
    checking for statvfs() … found
    checking for dlopen() … not found
    checking for dlopen() in libdl … found
    checking for sched_yield() … found
    checking for PCRE library … found
    checking for zlib library … found
    checking for perl
  • perl version: v5.8.8 built for i386-linux-thread-multi
  • perl interpreter multiplicity found
    creating objs/Makefile
    checking for int size … 4 bytes
    checking for long size … 4 bytes
    checking for long long size … 8 bytes
    checking for void * size … 4 bytes
    checking for uint64_t … found
    checking for sig_atomic_t … found
    checking for sig_atomic_t size … 4 bytes
    checking for socklen_t … found
    checking for in_addr_t … found
    checking for in_port_t … found
    checking for rlim_t … found
    checking for uintptr_t … uintptr_t found
    checking for system endianess … little endianess
    checking for size_t size … 4 bytes
    checking for off_t size … 8 bytes
    checking for time_t size … 4 bytes
    checking for setproctitle() … not found
    checking for pread() … found
    checking for pwrite() … found
    checking for strerror_r() … found but is not working
    checking for gnu style strerror_r() … found
    checking for localtime_r() … found
    checking for posix_memalign() … found
    checking for memalign() … found
    checking for mmap(MAP_ANON|MAP_SHARED) … found
    checking for mmap("/dev/zero", MAP_SHARED) … found
    checking for System V shared memory … found
    checking for struct msghdr.msg_control … found
    checking for ioctl(FIONBIO) … found
    checking for struct tm.tm_gmtoff … found
    checking for struct dirent.d_namlen … not found
    checking for struct dirent.d_type … found

Configuration summary

  • using system PCRE library
  • using OpenSSL library: /home/elove/openssl-0.9.8c
  • md5: using OpenSSL library
  • sha1 library is not used
  • using system zlib library

nginx path prefix: “/home/elove/app/nginx”
nginx binary file: “/home/elove/app/nginx/sbin/nginx”
nginx configuration prefix: “/home/elove/app/nginx/conf”
nginx configuration file: “/home/elove/app/nginx/conf/nginx.conf”
nginx pid file: “/home/elove/app/nginx/logs/nginx.pid”
nginx error log file: “/home/elove/app/nginx/logs/error.log”
nginx http access log file: “/home/elove/app/nginx/logs/access.log”
nginx http client request body temporary files: “client_body_temp”
nginx http proxy temporary files: “proxy_temp”
nginx http fastcgi temporary files: “fastcgi_temp”

#make

Omitted…

cp -p src/http/modules/perl/nginx.* objs/src/http/modules/perl/
cp -p src/http/modules/perl/typemap objs/src/http/modules/perl/
cp -p src/http/modules/perl/Makefile.PL objs/src/http/modules/perl/
cd objs/src/http/modules/perl
&& NGX_PM_CFLAGS="-D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe
-Wdeclaration-after-statement -I/usr/local/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm
-I/usr/lib/perl5/5.8.8/i386-linux-thread-multi/CORE -g "
NGX_PCRE=YES
NGX_OBJS=objs /usr/bin/perl Makefile.PL
LIB=/home/elove/app/nginx/modules/perl/
INSTALLSITEMAN3DIR=/home/elove/app/nginx/modules/perl//man3
Writing Makefile for nginx
cp -p src/http/modules/perl/nginx.* objs/src/http/modules/perl/
cd objs/src/http/modules/perl && make
make[2]: Entering directory
/home/elove/nginx-0.7.60/objs/src/http/modules/perl' cp nginx.pm blib/lib/nginx.pm /usr/bin/perl /usr/lib/perl5/5.8.8/ExtUtils/xsubpp -typemap /usr/lib/perl5/5.8.8/ExtUtils/typemap -typemap typemap nginx.xs > nginx.xsc && mv nginx.xsc nginx.c Please specify prototyping behavior for nginx.xs (see perlxs manual) gcc -c -I ../../../../../src/core -I ../../../../../src/event -I ../../../../../src/os/unix -I ../../../../../src/http -I ../../../../../src/http/modules -I ../../../../../src/http/modules/perl -I ../../../../../objs -D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe -Wdeclaration-after-statement -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -I/usr/lib/perl5/5.8.8/i386-linux-thread-multi/CORE -g -O -DVERSION=\"0.7.60\" -DXS_VERSION=\"0.7.60\" -fPIC "-I/usr/lib/perl5/5.8.8/i386-linux-thread-multi/CORE" nginx.c In file included from ../../../../../src/core/ngx_core.h:70, from nginx.xs:10: ../../../../../src/event/ngx_event_openssl.h:14:25: error: openssl/ssl.h: No such file or directory ../../../../../src/event/ngx_event_openssl.h:15:25: error: openssl/err.h: No such file or directory In file included from ../../../../../src/core/ngx_core.h:70, from nginx.xs:10: ../../../../../src/event/ngx_event_openssl.h:31: error: expected specifier-qualifier-list before 鈥楽SL_CTX鈥? ../../../../../src/event/ngx_event_openssl.h:37: error: expected specifier-qualifier-list before 鈥楽SL鈥? ../../../../../src/event/ngx_event_openssl.h:110: error: expected 鈥?鈥?before 鈥?鈥?token ../../../../../src/event/ngx_event_openssl.h:111: error: expected declaration specifiers or 鈥?..鈥?before 鈥楽SL_SESSION鈥? In file included from ../../../../../src/http/ngx_http.h:30, from nginx.xs:11: ../../../../../src/http/ngx_http_upstream_round_robin.h:33: error: expected specifier-qualifier-list before 鈥楽SL_SESSION鈥? make[2]: *** Error 1 make[2]: Leaving directory/home/elove/nginx-0.7.60/objs/src/http/modules/perl’
make[1]: *** Error 2
make[1]: Leaving directory `/home/elove/nginx-0.7.60’
make: *** Error 2

Posted at Nginx Forum:
http://forum.nginx.org/read.php?2,3276,3276#msg-3276

How to solve this error?

Posted at Nginx Forum:
http://forum.nginx.org/read.php?2,3276,3298#msg-3298

On Tue, Jun 23, 2009 at 10:09 PM, lankelan[email protected] wrote:

How to solve this error?

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,3276,3298#msg-3298

log please?

thans Maxim D., I resolved.

move nginx.pm into nginxpath/modules/perl/

Posted at Nginx Forum:
http://forum.nginx.org/read.php?2,3276,3323#msg-3323

Hello!

On Tue, Jun 23, 2009 at 03:24:20AM -0400, lankelan wrote:

#./configure --user=elove --group=elove --prefix=/home/elove/app/nginx --with-http_stub_status_module --with-http_ssl_module --with-openssl=/home/elove/openssl-0.9.8c --with-http_perl_module --with-perl=/usr/bin/perl --with-perl_modules_path=/home/elove/app/nginx/modules/perl/

[…]

…/…/…/…/…/src/event/ngx_event_openssl.h:111: error: expected declaration specifiers or 鈥?..鈥?before 鈥楽SL_SESSION鈥?
In file included from …/…/…/…/…/src/http/ngx_http.h:30,
from nginx.xs:11:
…/…/…/…/…/src/http/ngx_http_upstream_round_robin.h:33: error: expected specifier-qualifier-list before 鈥楽SL_SESSION鈥?
make[2]: *** Error 1
make[2]: Leaving directory /home/elove/nginx-0.7.60/objs/src/http/modules/perl' make[1]: *** Error 2 make[1]: Leaving directory/home/elove/nginx-0.7.60’
make: *** Error 2

Try the attached patch.

Maxim D.

Hello!

On Wed, Jun 24, 2009 at 06:26:54AM -0400, lankelan wrote:

thans Maxim D., I resolved.

move nginx.pm into nginxpath/modules/perl/

Actually, it should be in …/perl//nginx.pm. It looks
like your perl somewhat screwed up and doesn’t catch this
automatically as it should.

Maxim D.

Thanks Maxim D.

I attached patch and make success.
When start nginx print this error.

Can’t locate nginx.pm in @INC (@INC contains:
/home/elove/app/nginx/modules/perl
/usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7
/usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5
/usr/lib/perl5/site_perl
/usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi
/usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi
/usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi
/usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi
/usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7
/usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5
/usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi
/usr/lib/perl5/5.8.8 .).
BEGIN failed–compilation aborted.
: perl_parse() failed: 2

Posted at Nginx Forum:
http://forum.nginx.org/read.php?2,3276,3311#msg-3311

nginx tree

|-- client_body_temp
|-- conf
| |-- fastcgi_params
| |-- fastcgi_params.default
| |-- fcgi.conf
| |-- koi-utf
| |-- koi-win
| |-- mime.types
| |-- mime.types.default
| |-- nginx.conf
| |-- nginx.conf.default
| -- win-utf |-- fastcgi_temp |-- html | |-- 50x.html |– index.html
|-- logs
| |-- access.log
| |-- error.log
|-- modules
| -- perl | |-- i386-linux-thread-multi | | |-- auto | | |– nginx
| | | |-- nginx.bs
| | | -- nginx.so | | |-- nginx.pm | |– perllocal.pod
| -- man3 |– nginx.3pm
|-- proxy_temp
-- sbin– nginx

Posted at Nginx Forum:
http://forum.nginx.org/read.php?2,3276,3313#msg-3313

Hello!

On Tue, Jun 23, 2009 at 10:53:34PM -0400, lankelan wrote:

Thanks Maxim D.

I attached patch and make success.
When start nginx print this error.

Can’t locate nginx.pm in @INC (@INC contains: /home/elove/app/nginx/modules/perl /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.6/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl/5.8.6 /usr/lib/perl5/vendor_perl/5.8.5 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .).
BEGIN failed–compilation aborted.
: perl_parse() failed: 2

Looks like you haven’t run ‘make install’ and therefore there is
no nginx.pm in that perl can found. After ‘make install’ it
should appear in /home/elove/app/nginx/modules/perl.

Maxim D.

Hello,

how patch file plz ?

tsukasa.

Posted at Nginx Forum:
http://forum.nginx.org/read.php?2,3276,12120#msg-12120

Hello!

On Thu, Oct 08, 2009 at 01:44:51PM -0400, tsukasagenesis wrote:

Hello,

how patch file plz ?

Sorry, unable to parse your question.

If you aren’t able to find the patch in question, try looking more
thoroughly.

If you aren’t able to apply patch, try reading some docs about
patch(1) program. E.g. you may try wikipedia article here:

http://en.wikipedia.org/wiki/Patch_(Unix)

Maxim D.

Hello!

On Wed, Sep 22, 2010 at 10:29:57AM -0400, subeen wrote:

I am getting the same error (in centos54 nginx-0.7.67). I also tried the
patch, just edited the respective files by myself, but still getting the
error.

This is the error message I am getting:

-I/usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/CORE -g -O
-DVERSION=“0.7.67” -DXS_VERSION=“0.7.67” -fPIC
“-I/usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/CORE” nginx.c

[…]

In 0.7.67 you have to use updated patch, see here:

http://nginx.org/pipermail/nginx-devel/2010-January/000103.html
http://nginx.org/pipermail/nginx-devel/2010-January/000104.html

Maxim D.

I am getting the same error (in centos54 nginx-0.7.67). I also tried the
patch, just edited the respective files by myself, but still getting the
error.

This is the error message I am getting:

make[2]: Entering directory
`/root/nginx-0.7.67/objs/src/http/modules/perl'
gcc -c  -I ../../../../../src/core -I ../../../../../src/event -I
../../../../../src/os/unix -I ../../../../../src/http -I
../../../../../src/http/modules -I ../../../../../src/http/modules/perl
-I ../../../../../objs -I /root/pcre-8.10 -I
../../../../..//openssl/include  -D_REENTRANT -D_GNU_SOURCE
-fno-strict-aliasing -pipe -Wdeclaration-after-statement
-I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
-I/usr/include/gdbm
-I/usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/CORE -g  -O
-DVERSION=\"0.7.67\" -DXS_VERSION=\"0.7.67\" -fPIC
"-I/usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/CORE"   nginx.c
In file included from ../../../../../src/core/ngx_core.h:70,
                 from nginx.xs:10:
../../../../../src/event/ngx_event_openssl.h:14:25: error:
openssl/ssl.h: No such file or directory
../../../../../src/event/ngx_event_openssl.h:15:25: error:
openssl/err.h: No such file or directory
../../../../../src/event/ngx_event_openssl.h:16:26: error:
openssl/conf.h: No such file or directory
../../../../../src/event/ngx_event_openssl.h:17:28: error:
openssl/engine.h: No such file or directory
../../../../../src/event/ngx_event_openssl.h:18:25: error:
openssl/evp.h: No such file or directory
In file included from ../../../../../src/core/ngx_core.h:70,
                 from nginx.xs:10:
../../../../../src/event/ngx_event_openssl.h:28: error: expected
specifier-qualifier-list before ‘SSL_CTX’
../../../../../src/event/ngx_event_openssl.h:34: error: expected
specifier-qualifier-list before ‘SSL’
../../../../../src/event/ngx_event_openssl.h:109: error: expected
‘)’ before ‘*’ token
../../../../../src/event/ngx_event_openssl.h:110: error: expected
declaration specifiers or ‘...’ before ‘SSL_SESSION’
In file included from ../../../../../src/http/ngx_http.h:30,
                 from nginx.xs:11:
../../../../../src/http/ngx_http_upstream_round_robin.h:33: error:
expected specifier-qualifier-list before ‘SSL_SESSION’
make[2]: *** [nginx.o] Error 1
make[2]: Leaving directory
`/root/nginx-0.7.67/objs/src/http/modules/perl'
make[1]: *** [objs/src/http/modules/perl/blib/arch/auto/nginx/nginx.so]
Error 2
make[1]: Leaving directory `/root/nginx-0.7.67'
make: *** [build] Error 2

Posted at Nginx Forum:
http://forum.nginx.org/read.php?2,3276,132852#msg-132852

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs