[luatex] Accessing external Lua libraries

Faheem Mitha faheem at faheem.info
Wed Mar 24 17:58:50 CET 2021


On Wed, 24 Mar 2021, Faheem Mitha wrote:

> I'm not completely sure I understand what your issue is, but you might find 
> https://ctan.org/pkg/luapackageloader of interest if you aren't familiar with 
> it already. The strategy it uses is described somewhere in the LuaTeX manual 
> I think, though right now I can't remember exactly where.

I forgot to say that I use

package.cpath="/usr/local/lib/lua/5.3/?.so;/usr/lib/x86_64-linux-gnu/lua/5.3/?.so;/usr/lib/lua/5.3/?.so;/usr/local/lib/lua/5.3/loadall.so;./?.so"..package.cpath

package.path="/usr/local/share/lua/5.3/?.lua;/usr/local/share/lua/5.3/?/init.lua;/usr/local/lib/lua/5.3/?.lua;/usr/local/lib/lua/5.3/?/init.lua;/usr/share/lua/5.3/?.lua;/usr/share/lua/5.3/?/init.lua;./?.lua"..package.path

in my Lua files for use with LuaTeX, in conjunction with luapackageloader, 
and it seems to work. Though I can't remember whether I specifically 
needed to load an init.lua.

Hope this helps.

Regards, Faheem Mitha




More information about the luatex mailing list.