mirror of
https://github.com/neovim/neovim.git
synced 2025-10-21 09:12:07 +00:00
cmake/LuaHelpers.cmake: check_lua_module: use 'lua -l'
It only shortens the traceback a bit for when a module is not found though, only removing the "(command line):1: in main chunk" (with lua5.2).
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
|
||||
# Check if a module is available in Lua
|
||||
function(check_lua_module LUA_PRG_PATH MODULE RESULT_VAR)
|
||||
execute_process(COMMAND ${LUA_PRG_PATH} -e "require('${MODULE}')"
|
||||
execute_process(COMMAND ${LUA_PRG_PATH} -l "${MODULE}" -e ""
|
||||
RESULT_VARIABLE module_missing)
|
||||
if(module_missing)
|
||||
set(${RESULT_VAR} False PARENT_SCOPE)
|
||||
|
Reference in New Issue
Block a user