mirror of
https://github.com/optim-enterprises-bv/meta-openwrt.git
synced 2026-01-12 19:05:02 +00:00
Running the native lua5.1 binary to get the lua module path doesn't play
nice with using SSTATE with multiple build environments:
$ bitbake -e libubox | grep EXTRA_OECMAKE
# $EXTRA_OECMAKE [5 operations]
EXTRA_OECMAKE=" -DLUAPATH=`lua5.1 -e \"for k in string.gmatch(package.cpath .. \
\\";\\", \\"([^;]+)/..so;\\") do if k:sub(1,1) == \\"/\\" then print(k) \
break end end\" | \
sed 's#/home/troth/git/econe-yocto/build-morty-qemux86/tmp/sysroots/x86_64-linux##'` \
-DBUILD_EXAMPLES=ON -DBUILD_LUA=ON -DCMAKE_SKIP_RPATH=ON \${PACKAGECONFIG_CONFARGS}"
$ tmp/sysroots/x86_64-linux/usr/bin/lua5.1 -e "for k in string.gmatch(package.cpath .. \
\";\", \"([^;]+)/..so;\") do if k:sub(1,1) == \"/\" then print(k) break end end"
/home/troth/git/econe-yocto/build-morty/tmp/sysroots/x86_64-linux/usr/lib/lua/5.1
Just use a fixed string for the path instead of trying to programmatically generate it.
Signed-off-by: Theodore A. Roth <theodore_roth@trimble.com>