I put an issue on leafo's lapis github,
https://github.com/leafo/lapis/issues/539
I'm also interested in learning some way to ignore a dependency. I probably won't spend the time on a short-term rockspec fix, better to figure out a good path forward.
Erik
> -----Original Message-----
> From: openresty-en@googlegroups.com [mailto:openresty-
> en@googlegroups.com] On Behalf Of Thibault Charbonnier
> Sent: Tuesday, April 25, 2017 3:13 PM
> To: openresty-en@googlegroups.com
> Subject: Re: [openresty-en] openresty-1.11.2.3 and cjson error
>
> I see. The OpenResty fork has a fix for this already:
>
> https://github.com/openresty/lua-cjson/pull/22
>
> However, I don't know of a way to make LuaRocks ignore this specific
> dependency. Ideally, and because mpx/lua-cjson has become (or seems to
> be) un-maintained, I would suggest that you contact the Lapis author to
> consider changing its dependency on it to openresty/lua-cjson instead.
>
> As a short term solution, have you considered writing your own rockspec
> for your Lapis installation? I think that would be reasonable. If
> anybody knows of another way to ignore a LuaRocks dependency, I would
> love to hear about it as well!
>
> --
> Thibault
>
> On 4/25/17 11:54 AM, 'Nelson, Erik - 2' via openresty-en wrote:
> > Confirming that it's being pulled in as part of the lapis dependencies,
> complete log is below.
> >
> >>> -----Original Message-----
> >>> From: openresty-en@googlegroups.com [mailto:openresty-
> >>> en@googlegroups.com] On Behalf Of Thibault Charbonnier
> >>> Sent: Tuesday, April 25, 2017 1:34 PM
> >>> To: openresty-en@googlegroups.com
> >>> Subject: Re: [openresty-en] openresty-1.11.2.3 and cjson error
> >>>
> >>> Hi,
> >>>
> >>> FYI, did you know OpenResty bundles it own (improved) version of
> >>> lua-cjson? It seems to me like you are trying to install mpx/lua-cjson
> >>> from LuaRocks while you don't need to.
> >>>
> >>> See:
> >>>
> >>> https://github.com/openresty/lua-cjson
> >>>
> >
> **********************************************************
> **************
> > Installing https://luarocks.org/lapis-1.5.1-1.src.rock
> > Missing dependencies for lapis 1.5.1-1:
> > ansicolors (not installed)
> > date (not installed)
> > etlua (not installed)
> > loadkit (not installed)
> > lpeg (not installed)
> > lua-cjson (not installed)
> > luacrypto (not installed)
> > luafilesystem (not installed)
> > luasocket (not installed)
> > mimetypes (not installed)
> > pgmoon >= 1.2.0 (not installed)
> >
> > lapis 1.5.1-1 depends on ansicolors (not installed)
> > Installing https://luarocks.org/ansicolors-1.0.2-3.src.rock
> > No existing manifest. Attempting to rebuild...
> > ansicolors 1.0.2-3 is now installed in /openresty-1.11.2.3/luajit (license: MIT
> <http://opensource.org/licenses/MIT>)
> >
> > lapis 1.5.1-1 depends on date (not installed)
> > Installing https://luarocks.org/date-2.1.2-1.src.rock
> > date 2.1.2-1 is now installed in /openresty-1.11.2.3/luajit (license: MIT)
> >
> > lapis 1.5.1-1 depends on etlua (not installed)
> > Installing https://luarocks.org/etlua-1.3.0-1.src.rock
> > etlua 1.3.0-1 is now installed in /openresty-1.11.2.3/luajit (license: MIT)
> >
> > lapis 1.5.1-1 depends on loadkit (not installed)
> > Installing https://luarocks.org/loadkit-1.1.0-1.src.rock
> > loadkit 1.1.0-1 is now installed in /openresty-1.11.2.3/luajit (license: MIT)
> >
> > lapis 1.5.1-1 depends on lpeg (not installed)
> > Installing https://luarocks.org/lpeg-1.0.1-1.src.rock
> > In file included from lpcap.h:9:0,
> > from lpcap.c:9:
> > lptypes.h:42:0: warning: "luaL_newlib" redefined [enabled by default]
> > #define luaL_newlib(L,f) luaL_register(L,"lpeg",f)
> > ^
> > In file included from lpcap.c:7:0:
> > /openresty-1.11.2.3/luajit/include/luajit-2.1/lauxlib.h:123:0: note: this is
> the location of the previous definition
> > #define luaL_newlib(L, l) (luaL_newlibtable(L, l), luaL_setfuncs(L, l, 0))
> > ^
> > In file included from lpcode.c:12:0:
> > lptypes.h:42:0: warning: "luaL_newlib" redefined [enabled by default]
> > #define luaL_newlib(L,f) luaL_register(L,"lpeg",f)
> > ^
> > In file included from lpcode.c:10:0:
> > /openresty-1.11.2.3/luajit/include/luajit-2.1/lauxlib.h:123:0: note: this is
> the location of the previous definition
> > #define luaL_newlib(L, l) (luaL_newlibtable(L, l), luaL_setfuncs(L, l, 0))
> > ^
> > In file included from lptree.c:14:0:
> > lptypes.h:42:0: warning: "luaL_newlib" redefined [enabled by default]
> > #define luaL_newlib(L,f) luaL_register(L,"lpeg",f)
> > ^
> > In file included from lptree.c:12:0:
> > /openresty-1.11.2.3/luajit/include/luajit-2.1/lauxlib.h:123:0: note: this is
> the location of the previous definition
> > #define luaL_newlib(L, l) (luaL_newlibtable(L, l), luaL_setfuncs(L, l, 0))
> > ^
> > In file included from lpcap.h:9:0,
> > from lpvm.c:13:
> > lptypes.h:42:0: warning: "luaL_newlib" redefined [enabled by default]
> > #define luaL_newlib(L,f) luaL_register(L,"lpeg",f)
> > ^
> > In file included from lpvm.c:11:0:
> > /openresty-1.11.2.3/luajit/include/luajit-2.1/lauxlib.h:123:0: note: this is
> the location of the previous definition
> > #define luaL_newlib(L, l) (luaL_newlibtable(L, l), luaL_setfuncs(L, l, 0))
> > ^
> > gcc -O2 -fPIC -I/openresty-1.11.2.3/luajit/include/luajit-2.1 -c lpcap.c -o
> lpcap.o
> > gcc -O2 -fPIC -I/openresty-1.11.2.3/luajit/include/luajit-2.1 -c lpcode.c -o
> lpcode.o
> > gcc -O2 -fPIC -I/openresty-1.11.2.3/luajit/include/luajit-2.1 -c lpprint.c -o
> lpprint.o
> > gcc -O2 -fPIC -I/openresty-1.11.2.3/luajit/include/luajit-2.1 -c lptree.c -o
> lptree.o
> > gcc -O2 -fPIC -I/openresty-1.11.2.3/luajit/include/luajit-2.1 -c lpvm.c -o
> lpvm.o
> > gcc -shared -o lpeg.so -L/openresty-1.11.2.3/luajit//lib lpcap.o lpcode.o
> lpprint.o lptree.o lpvm.o
> > lpeg 1.0.1-1 is now installed in /openresty-1.11.2.3/luajit (license: MIT/X11)
> >
> > lapis 1.5.1-1 depends on lua-cjson (not installed)
> > Installing https://luarocks.org/lua-cjson-2.1.0-1.src.rock
> > lua_cjson.c:1298:13: error: static declaration of ‘luaL_setfuncs’ follows non-
> static declaration
> > static void luaL_setfuncs (lua_State *l, const luaL_Reg *reg, int nup)
> > ^
> > In file included from lua_cjson.c:44:0:
> > /openresty-1.11.2.3/luajit/include/luajit-2.1/lauxlib.h:88:18: note: previous
> declaration of ‘luaL_setfuncs’ was here
> > LUALIB_API void (luaL_setfuncs) (lua_State *L, const luaL_Reg *l, int nup);
> > ^
> >
> > Error: Failed installing dependency: https://luarocks.org/lua-cjson-2.1.0-
> 1.src.rock - Build error: Failed compiling object lua_cjson.o
> > gcc -O2 -fPIC -I/openresty-1.11.2.3/luajit/include/luajit-2.1 -c lua_cjson.c -o
> lua_cjson.o
> >
> >
> >
> > ----------------------------------------------------------------------
> > This message, and any attachments, is for the intended recipient(s) only,
> may contain information that is privileged, confidential and/or proprietary
> and subject to important terms and conditions available at
> http://www.bankofamerica.com/emaildisclaimer. If you are not the
> intended recipient, please delete this message..
----------------------------------------------------------------------
This message, and any attachments, is for the intended recipient(s) only, may contain information that is privileged, confidential and/or proprietary and subject to important terms and conditions available at http://www.bankofamerica.com/emaildisclaimer. If you are not the intended recipient, please delete this message.