Forum: NGINX error while building own nginx module

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
F2392b959985016ca5dacd2b70ce6389?d=identicon&s=25 Pankaj Chaudhary (Guest)
on 2016-07-20 16:13
(Received via mailing list)
Hi

i have written  own nginx module and i have many header ,src and
makefiles
files .

 my nginx module folder structure look like below

/product/src/nginx/ngx_http_auth_module.cpp
/product/src/nginx/Makefile
/product/src/nginx/config(nginx config file)
/product/src/common/.cpp files
/product/lib/.so files
/product/src/utility/.c and .h files

i have written my config file like this
***************************************************************
ngx_module_type=HTTP_AUX_FILTER_MODULES
ngx_module_name=ngx_http_auth_module
ngx_module_incs=$ngx_addon_dir
ngx_module_deps=
ngx_module_srcs=$ngx_addon_dir/ngx_http_auth_module.cpp \
                $ngx_addon_dir/Makefile

ngx_module_libs=

. auto/module
***************************************************************************
code  build  successfully and generated  ngx_http_auth_module.so file
but
not correctly since i am getting below  error while loading in
nginx.conf
file.

nginx: [emerg] dlopen()
"/usr/local/nginx/modules/ngx_http_auth_module.so"
failed (/usr/local/nginx/modules/ngx_http_auth_module.so: undefined
symbol:
ngx_http_auth_module

Please let me know correct way to do.

Thanks & Regards,
Pankaj Chaudhary
This topic is locked and can not be replied to.