lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Sat, Aug 23, 2008 at 3:00 AM, David Manura <dm.lua@math2.org> wrote:
RJP Computing writes:
> The change I am proposing is to add 'clib' to the LUA_CPATH
> example LUA_CPATH: ;;?.dll;<lua_dir>\clibs\?.dll;...

In general, this may be a good idea.

However, in the case of Lua for Windows, if it incorporates LuaRocks, the search
paths will be determined by LuaRocks, which redefines the "require" function and
imposes it's own "appdir" isolated per-package directory structure[1-2], similar
to those seen in OS X and elsewhere[3-4].  This differs from the flat directory
structure typical in UNIX, currently used in Lua for Windows, and implied in the
above suggestion.

 [1] http://lists.luaforge.net/pipermail/luarocks-developers/2007-May/000032.html
 [2] http://www.luarocks.org/en/Using_LuaRocks
 [3] http://freshmeat.net/articles/view/247/
 [4] http://relink.sourceforge.net/

What if you didn't use LuaRocks in the exact way that it was intended and only used it to get new modules. Specifically, I am saying _not_ to use the 'require "luarocks.require"' statement at all. Then use LuaRocks to install the modules into a directory that LfW has already setup, to look in for new modules. I understand that this takes some functionality away, but I think this is about the best way to use LuaRocks in LfW right now.
--
Regards,
Ryan
RJP Computing