May 12, 2011 02:56AM
Добрый день. Мне нужно написать простенький модуль для nginx. Нашел пример :
1
2 // stub module to test header files' C++ compatibilty
3
4 extern "C" {
5 #include <ngx_config.h>
6 #include <ngx_core.h>
7 #include <ngx_event.h>
8 #include <ngx_event_connect.h>
9 #include <ngx_event_pipe.h>
10
11 #include <ngx_http.h>
12
13 #include <ngx_mail.h>
14 #include <ngx_mail_pop3_module.h>
15 #include <ngx_mail_imap_module.h>
16 #include <ngx_mail_smtp_module.h>
17 }
18
19 // nginx header files should go before other, because they define 64-bit off_t
20 // #include <string>
21
22
23 void
24 ngx_cpp_test_handler(void *data)
25 {
26 return;
27 }
28

Но вот проблема модуль не компилируется, вылезает ошибка что ngx_config.h и другие файлы не найдены. Я устанавливал nginx на ubuntu. Использовал следующие команды :
sudo aptitude install nginx

aptitude install libcurl4-openssl-dev libpcre++-dev

./configure --sbin-path=/usr/sbin/nginx --conf-path=/etc/nginx/nginx.conf --pid-path=/var/run/nginx.pid

make

make install

может что-то пропустил и у меня эти файлы не установились ?
Subject Author Posted

проблема с "hello world" модулем

Bdfy August 06, 2010 11:08AM

Re: проблема с "hello world" модулем

Maxim Dounin August 07, 2010 04:42PM

Re: проблема с "hello world" модулем

Ildar May 12, 2011 02:56AM

Re: проблема с "hello world" модулем

Ildar May 12, 2011 03:25PM

Re: проблема с "hello world" модулем

jjjx128 May 12, 2011 07:11PM

Re: проблема с "hello world" модулем

Ildar May 13, 2011 12:43AM

Re: проблема с "hello world" модулем

vt May 12, 2011 08:24AM

Re: проблема с "hello world" модулем

Rush May 12, 2011 12:56PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 103
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready