Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nginx 1.9.12 compatibilty ? #23

Open
centminmod opened this issue Mar 20, 2016 · 5 comments
Open

nginx 1.9.12 compatibilty ? #23

centminmod opened this issue Mar 20, 2016 · 5 comments

Comments

@centminmod
Copy link

Tried compiling lua-upstream-nginx-module-0.05 and seems to fail on nginx 1.9.12

nginx configure options (alternate ordering):
./configure --with-ld-opt="-ljemalloc -Wl,-z,relro -Wl,-rpath,/usr/local/lib" --with-cc-opt="-m64 -mtune=native -mfpmath=sse -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2" --sbin-path=/usr/local/sbin/nginx --conf-path=/usr/local/nginx/conf/nginx.conf --with-http_stub_status_module --with-http_secure_link_module --with-openssl-opt="enable-tlsext" --add-module=../nginx-module-vts --with-libatomic --with-threads --with-stream=dynamic --with-stream_ssl_module --with-http_gzip_static_module --add-dynamic-module=../ngx_brotli --add-dynamic-module=../ngx_pagespeed-release-1.10.33.6-beta --with-http_sub_module --with-http_addition_module --with-http_image_filter_module=dynamic --with-http_geoip_module=dynamic --with-http_realip_module --add-module=../ngx-fancyindex-0.3.6 --add-module=../ngx_cache_purge-2.3 --add-module=../ngx_devel_kit-0.3.0rc1 --add-dynamic-module=../set-misc-nginx-module-0.30 --add-dynamic-module=../echo-nginx-module-0.58 --add-module=../redis2-nginx-module-0.12 --add-module=../ngx_http_redis-0.3.7 --add-dynamic-module=../lua-nginx-module-0.10.2 --add-module=../lua-upstream-nginx-module-0.05 --add-module=../nginx_upstream_check_module-0.3.0 --add-module=../openresty-memc-nginx-module-4f6f78f --add-module=../srcache-nginx-module-0.30 --add-dynamic-module=../headers-more-nginx-module-0.29 --with-pcre=../pcre-8.38 --with-pcre-jit --with-http_ssl_module --with-http_v2_module --with-openssl=../openssl-1.0.2g
checking for OS

  • Linux 2.6.32-042stab112.15 x86_64
    checking for C compiler ... found
  • using GNU C compiler
  • gcc version: 4.8.5 20150623 (Red Hat 4.8.5-4) (GCC)
configuring additional modules
adding module in ../nginx-module-vts
 + ngx_http_vhost_traffic_status_module was configured
adding module in ../ngx-fancyindex-0.3.6
 + ngx_http_fancyindex_module was configured
adding module in ../ngx_cache_purge-2.3
 + ngx_http_cache_purge_module was configured
adding module in ../ngx_devel_kit-0.3.0rc1
 + ngx_devel_kit was configured
adding module in ../redis2-nginx-module-0.12
 + ngx_http_redis2_module was configured
adding module in ../ngx_http_redis-0.3.7
 + ngx_http_redis_module was configured
adding module in ../lua-upstream-nginx-module-0.05
 + ngx_http_lua_upstream_module was configured
adding module in ../nginx_upstream_check_module-0.3.0
checking for ngx_http_upstream_check_module ... found
 + ngx_http_upstream_check_module was configured
adding module in ../openresty-memc-nginx-module-4f6f78f
 + ngx_http_memc_module was configured
adding module in ../srcache-nginx-module-0.30
 + ngx_http_srcache_filter_module was configured
configuring additional dynamic modules
adding module in ../ngx_brotli
checking for Brotli library ... found
 + ngx_brotli was configured
adding module in ../ngx_pagespeed-release-1.10.33.6-beta
mod_pagespeed_dir=../ngx_pagespeed-release-1.10.33.6-beta/psol/include
build_from_source=false
checking for psol ... found
List of modules (in reverse order of applicability):  ngx_http_write_filter_module ngx_http_header_filter_module ngx_http_chunked_filter_module ngx_http_v2_filter_module ngx_http_range_header_filter_module ngx_http_gzip_filter_module ngx_http_postpone_filter_module ngx_http_ssi_filter_module ngx_http_charset_filter_module ngx_http_sub_filter_module ngx_http_addition_filter_module ngx_http_userid_filter_module ngx_http_headers_filter_module
checking for psol-compiler-compat ... found
 + ngx_pagespeed was configured
adding module in ../set-misc-nginx-module-0.30
found ngx_devel_kit for ngx_set_misc; looks good.
 + ngx_http_set_misc_module was configured
adding module in ../echo-nginx-module-0.58
 + ngx_http_echo_module was configured
adding module in ../lua-nginx-module-0.10.2
checking for LuaJIT library in /usr/local/lib and /usr/local/include/luajit-2.1 (specified by the LUAJIT_LIB and LUAJIT_INC env, with -ldl) ... found
checking for export symbols by default (-E) ... found
checking for export symbols by default (--export-all-symbols) ... not found
checking for SO_PASSCRED ... found
 + ngx_http_lua_module was configured
adding module in ../headers-more-nginx-module-0.29
 + ngx_http_headers_more_filter_module was configured
checking for zlib library ... found
checking for GD library ... found
checking for GeoIP library ... found
checking for atomic_ops library ... found
creating objs/Makefile
objs/addon/src/ngx_http_lua_upstream_module.o: In function `ngx_http_lua_upstream_get_upstreams':
/svr-setup/nginx-1.9.12/../lua-upstream-nginx-module-0.05/src/ngx_http_lua_upstream_module.c:112: undefined reference to `lua_gettop'
/svr-setup/nginx-1.9.12/../lua-upstream-nginx-module-0.05/src/ngx_http_lua_upstream_module.c:119: undefined reference to `lua_createtable'
/svr-setup/nginx-1.9.12/../lua-upstream-nginx-module-0.05/src/ngx_http_lua_upstream_module.c:134: undefined reference to `lua_rawseti'
/svr-setup/nginx-1.9.12/../lua-upstream-nginx-module-0.05/src/ngx_http_lua_upstream_module.c:125: undefined reference to `lua_pushlstring'
/svr-setup/nginx-1.9.12/../lua-upstream-nginx-module-0.05/src/ngx_http_lua_upstream_module.c:127: undefined reference to `lua_pushfstring'
/svr-setup/nginx-1.9.12/../lua-upstream-nginx-module-0.05/src/ngx_http_lua_upstream_module.c:128: undefined reference to `lua_concat'
/svr-setup/nginx-1.9.12/../lua-upstream-nginx-module-0.05/src/ngx_http_lua_upstream_module.c:113: undefined reference to `luaL_error'
collect2: error: ld returned 1 exit status
make[1]: *** [objs/nginx] Error 1
make[1]: Leaving directory `/svr-setup/nginx-1.9.12'
make: *** [build] Error 2
@agentzh
Copy link
Member

agentzh commented Mar 20, 2016

@centminmod I failed to reproduce this on my side with the same versions of nginx, ngx_lua, and ngx_lua_upstream. Your output log is incomplete. Will you provide the output lines right above the line objs/addon/src/ngx_http_lua_upstream_module.o: In function``ngx_http_lua_upstream_get_upstreams':? Or better, provide the complete output pasted on gist (you can share the link to gist here).

@centminmod
Copy link
Author

@agentzh
Copy link
Member

agentzh commented Mar 21, 2016

@centminmod Okay, I see what's going on here. Because you built ngx_lua as a DSO module, the ngx_lua_upstream module must also be built as a DSO module since it depends on ngx_lua.

@agentzh
Copy link
Member

agentzh commented Mar 21, 2016

@centminmod Try replacing --add-module=../lua-upstream-nginx-module-0.05 with --add-dynamic-module=../lua-upstream-nginx-module-0.05.

@centminmod
Copy link
Author

@agentzh i see - have roadblock with lua-nginx-module as dynamic module at openresty/lua-nginx-module#715 so I guess for now compiling both as non-dynamic is easiest way

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants