[OpenWrt-Devel] [PATCH 1/1] libubox/lua/CMakeLists.txt: fix LUAPATH so it will use /usr/lib/ instead of /usr/local/lib/

Petr Štetiar ynezz at true.cz
Thu Nov 29 11:26:58 EST 2018


Sergey Ponomarev <stokito at gmail.com> [2018-11-29 17:20:08]:

BTW, you're missing commit message here, and you don't usually send cover
letters for single patches like this one. It's enough to do:

git format-patch -s1
git send-email ...

>  IF(NOT LUAPATH)
>  	EXECUTE_PROCESS(
> -		COMMAND  lua -e "for k in string.gmatch(package.cpath .. \";\", \"([^;]+)/..so;\") do if k:sub(1,1) == \"/\" then print(k) break end end"
> +		COMMAND  lua -e "for k in string.gmatch(package.cpath .. \";\", \"([^;]+)/..so;\") do if k:sub(1,9) == \"/usr/lib/\" then print(k) break end end"

Can't you just provide proper(expected) LUAPATH from your build script? I'm
for example using this for testing:

 rm -fr build ; mkdir build ; cd build
 cmake \
        -D CMAKE_INSTALL_PREFIX=/opt/devel/openwrt/testing \
        -D BUILD_LUA=on \
        -D LUAPATH=/opt/devel/openwrt/testing/lib/lua/5.1 \
        ..
 make install VERBOSE=99

-- ynezz

_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list