[Lldb-commits] [lldb] [lldb][test] skip Lua tests when the Lua interpreter is not found (PR #164793)
    Vincent Palatin via lldb-commits 
    lldb-commits at lists.llvm.org
       
    Fri Oct 24 00:59:59 PDT 2025
    
    
  
================
@@ -158,7 +158,11 @@ def get_tests(self):
         return tests
 
     def test_lua_api(self):
-        if "LUA_EXECUTABLE" not in os.environ or len(os.environ["LUA_EXECUTABLE"]) == 0:
+        if (
+            "LUA_EXECUTABLE" not in os.environ
+            or len(os.environ["LUA_EXECUTABLE"]) == 0
+            or "NOTFOUND" in os.environ["LUA_EXECUTABLE"]
+        ):
----------------
vpalatin wrote:
yes, it's a nicest and more generic way, I will update the patch.
By the way,  while verifying the patch for the maybe-exotic corner case, I noticed that `LUAANDSWIG_FOUND` is incorrectly defined (to `1`) too as the `find_package_handle_standard_args(LuaAndSwig` call in `lldb/cmake/modules/FindLuaAndSwig.cmake` is not checking the `LUA_EXECUTABLE` variable (which is `LUA_EXECUTABLE-NOTFOUND` in this case. I think it is worth adding too.
https://github.com/llvm/llvm-project/pull/164793
    
    
More information about the lldb-commits
mailing list