Wesnoth appears to use bundled Lua, at least in 1.18.4 and 1.19.11. The last mention of the dev-lang/lua dep seems to be in: commit 9320a11fecbd758ca073072ebc06750313fbcdbb Author: Andreas Sturmlechner <asturm@gentoo.org> Date: Sun Jun 3 15:54:54 2018 +0200 games-strategy/wesnoth: Drop old Package-Manager: Portage-2.3.40, Repoman-2.3.9 But it takes ages and ages after that to get to the commit which *dropped* dev-lang/lua, which is weird, as I was expecting to find some commit dropping it (rather than just a cleanup of old). It looks like it actually never got propagated to the newer version for bug 299068: commit 97a77fda06586b1d1a42b6a707bd603d61ed24c1 Author: Michael Sterrett <mr_bones_@gentoo.org> Date: Thu Dec 31 17:04:21 2009 +0000 needs lua to build as well (bug #299068) (Portage version: 2.1.6.13/cvs/Linux i686) which added it to 1.7.x, but not 1.6.x actually? Whatever. Anyway, CMakeLists.txt on master has: ``` if(NOT WIN32) set(Lua_FIND_VERSION_MAJOR 5) set(Lua_FIND_VERSION_MINOR 4) option(ENABLE_SYSTEM_LUA "Enable use of system Lua ${Lua_FIND_VERSION_MAJOR}.${Lua_FIND_VERSION_MINOR} (compiled as C++)" OFF) endif() if(ENABLE_SYSTEM_LUA) set(Lua_FIND_VERSION_EXACT ON) set(Lua_FIND_VERSION_COUNT 2) include(FindLua) if(NOT LUA_FOUND) message(FATAL_ERROR "Lua ${Lua_FIND_VERSION_MAJOR}.${Lua_FIND_VERSION_MINOR} C++ not found. Try setting 'LUA_DIR'.") endif() else() if(NOT EXISTS "${CMAKE_SOURCE_DIR}/src/modules/lua/.git") message(FATAL_ERROR "Lua submodule does not exist. You must run 'git submodule update --init --recursive' to initialize it.") else() message("-- Lua submodule found.") endif() endif() ``` We should set ENABLE_SYSTEM_LUA and wire up use of the lua-* eclass.