You may have better luck modifying the LUA_PATH environment variable *before* you run lua/pandoc.

http://www.thijsschreijer.nl/blog/?p=1025

Also there may be problems using non-pure-lua modules if you use the downloadable relocatable pandoc binary. I guess that is what you are running into here.


Den mån 8 juli 2019 14:44K4zuki <k.yamamoto.08136891-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> skrev:
Hello,

I am facing a little problem around lua and pre-compiled dynamic libraries(*.so).

On Ubuntu 18.04(bionic), I have installed 'lyaml' and 'lfs' modules through 'lua-yaml' and 'lua-filesystem' APT packages.
Pandoc version is 2.7.3

When I try to load lyaml by simplest statement like following, Pandoc-lua raises error
```input
package.path = package.path .. ';/usr/share/lua/5.3/?.lua'
package.cpath = package.cpath .. ";/usr/lib/x86_64-linux-gnu/lua/5.3"
-- those 2 lines above are required to load 
local lyaml = require("lyaml")
```
---
```output
error loading module 'yaml' from file '/usr/lib/x86_64-linux-gnu/lua/5.3/yaml.so':
        Dynamic loading not supported
stack traceback:
        [C]: in ?
        [C]: in function 'require'
        /usr/share/lua/5.3/lyaml.lua:31: in main chunk
        [C]: in function 'require'
        ../lua/test.lua:5: in main chunk
```
lfs is similar like so:
```
error loading module 'lfs' from file '/usr/lib/x86_64-linux-gnu/lua/5.3/lfs.so':
        Dynamic loading not supported
stack traceback:
        [C]: in ?
        [C]: in function 'require'
        ../lua/test.lua:8: in main chunk
```

How can we solve this, or do we need to use static libs only?

Thanks && Regards,
Kazuki / K4zuki

--
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh4Ykp1iOSErHA@public.gmane.orgm.
To post to this group, send email to pandoc-discuss@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/4337b7eb-3ed7-4a70-a9f5-ecccc625c7d8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/CAFC_yuSiX5iPeh69vpy4bB9ZSYPB%2BBHtZEMJCykHMqgLyRMWJw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.