aboutsummaryrefslogtreecommitdiff
path: root/cmake/LuaHelpers.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/LuaHelpers.cmake')
-rw-r--r--cmake/LuaHelpers.cmake7
1 files changed, 3 insertions, 4 deletions
diff --git a/cmake/LuaHelpers.cmake b/cmake/LuaHelpers.cmake
index 32f7e46a57..0239460f2b 100644
--- a/cmake/LuaHelpers.cmake
+++ b/cmake/LuaHelpers.cmake
@@ -4,9 +4,8 @@
# 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}')"
- RESULT_VARIABLE module_missing
- ERROR_QUIET)
+ execute_process(COMMAND ${LUA_PRG_PATH} -l "${MODULE}" -e ""
+ RESULT_VARIABLE module_missing)
if(module_missing)
set(${RESULT_VAR} False PARENT_SCOPE)
else()
@@ -18,7 +17,7 @@ endfunction()
function(check_lua_deps LUA_PRG_PATH MODULES RESULT_VAR)
# Check if the lua interpreter at the given path
# satisfies all Neovim dependencies
- message(STATUS "Checking Lua interpreter ${LUA_PRG_PATH}")
+ message(STATUS "Checking Lua interpreter: ${LUA_PRG_PATH}")
if(NOT EXISTS ${LUA_PRG_PATH})
message(STATUS
"[${LUA_PRG_PATH}] file not found")