Commit graph

11 commits

Author SHA1 Message Date
Gunter Labes
9da0fbcc23 Keep python 2 compatibility 2024-03-28 17:06:00 +01:00
P. J. McDermott
69fa5c199e Add CMake and SCons options to use system Lua 5.4 C++
scons/lua.py makes use of the vestigial luadir option from commit
e94dcecf17.

Like FindLua.cmake, scons/lua.py searches for the Lua headers and
library, instead of using pkg-config like the old scons/lua.py (removed
in commit 9929d3ca1c) did, because even though distributions typically
provide .pc files for Lua, upstream Lua doesn't.  It's likely that all
distributions that compile Lua as a C++ library will also provide .pc
files, but this check doesn't rely on that (just as the CMake module
doesn't).

Unfortunately, SCons.Conftest.CheckLib() prints up to eight messages
like "Checking for C++ library lua54-c++... no" until a working library
name is found.

Also conditionally include system Lua headers in src/lua/*.h and update
documentation in src/modules/lua_README.md, src/wesnoth_lua_config.h,
and src/wesnoth_lua_config.md.  The two lines about "The primary commit,
after replacing the sources," in src/wesnoth_lua_config.md don't make
sense since the instructions were updated for submodule Lua in commit
d32cfb88c4 and make even less sense now with preceding commits for
updating CMake modules.
2024-02-11 23:21:15 -06:00
Pentarctagon
9929d3ca1c Remove some unused scons code. 2022-05-03 20:36:00 -05:00
anatoly techtonik
5e3ee31a99 scons: find_include simplify API 2014-06-08 15:49:00 +03:00
Sergey Popov
cf831db47b Fixed lua check
The test program was missing #include <lauxlib.h> but
used luaL_newstate() which is defined in it.
2009-06-23 00:53:35 +00:00
Iurii Chernyi
af320fc046 Improved lua detection to work on FreeBSD7...
...(which uses lua-5.1.pc) Now scons can compile trunk on FreeBSD7
without any os-specific patches.
2009-04-25 15:47:25 +00:00
Sergey Popov
01de0050e6 Added some diagnostic output to lua and pkg-config checks.
(written to build/config.log)
2009-03-27 13:48:45 +00:00
Sergey Popov
b2829b1a1a Added support for finding lua without pkg-config. 2009-03-27 12:26:14 +00:00
Sergey Popov
c42a66d370 Prevent lua check from adding flags to env when it fails. 2009-03-26 20:23:30 +00:00
Sergey Popov
758d64adf5 Clarified message in lua check. 2009-03-24 14:05:11 +00:00
Sergey Popov
e94dcecf17 Added a custom check for lua. 2009-03-23 01:26:52 +00:00