[vlc-devel] [PATCH] Revert "lua: don't call directly config_GetLibDir"
kwizart at gmail.com
Tue Aug 1 10:57:56 CEST 2017
2017-07-31 17:08 GMT+02:00 Rémi Denis-Courmont <remi at remlab.net>:
> Le maanantaina 31. heinäkuuta 2017, 11.57.18 EEST Nicolas Chauvet a écrit :
>> This fix lua modules loading such as http interface and youtube scripts.
>> libdir and datadir are differents kind of directories on Linux.
>> The former is for arch dependent content whereas the latter is arch
>> In the case of luac files, the man luac page says
>> "Precompiled chunks are not portable across different architectures."
>> So theses files qualifies as been located in a "libdir" directory
> How so? VLC explicitly forces the 32-bits scalar ABI for Lua byte code, and
> only officially supports little endian (patch welcome to fix big endian). This
> is necessary to exchange third-party Lua scripts.
> So AFAIK, VLC Lua byte code is architecture-independent, and that is very much
> by design.
Older lua man pages (<=5.1) said lua byte code "are portable only
among architectures with the same word size and byte order."
But there is no mention of OS compatibility, or compatibility across
This is not the case anymore with lua 5.2 and later, as quoted earlier.
I don't expect I can have 32bit lua 5.2 on ppc64le or aarch64 anyway...
So, if targeting portability is the aim, isn't that more efficient to
use plain lua text files instead ?
Thx for your answer and review.
More information about the vlc-devel