diff options
author | Jeff Morriss <jeff.morriss.ws@gmail.com> | 2015-06-05 22:04:29 -0400 |
---|---|---|
committer | Alexis La Goutte <alexis.lagoutte@gmail.com> | 2015-06-08 08:13:09 +0000 |
commit | 032ad5a7aa4e807f6389713f4339eddac2e254fa (patch) | |
tree | e31b7fcf348bb20f31102227672d1fe037c9a4e6 /cmake | |
parent | da1766e9871ba1eb4156ebd05c819eee9d91c10f (diff) |
Update how we search for Lua with pkg-config.
First, search for packages with the version number without the period (bug
11219).
Second, don't look for Lua 5.3 because we don't work with it. If what we find
(without pkg-config's help) is Lua 5.3, disable Lua support (bug 10881).
Cmake support by Peter Wu (originally Ie73e5b53640f10432881a9671c0a605f7f027ed8):
Note the check for "lua<=5.2.99" instead of "lua<5.3" since cmake does not
support the latter syntax. Tested with lua5.2, lua5.1 and lua (5.3) installed.
Bug: 11219
Ping-Bug: 10881
Change-Id: I382d07ca00eafc6111cd4e9faa2b66f6b8f95b6e
Reviewed-on: https://code.wireshark.org/review/8783
Petri-Dish: Jeff Morriss <jeff.morriss.ws@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Diffstat (limited to 'cmake')
-rw-r--r-- | cmake/modules/FindLUA.cmake | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/cmake/modules/FindLUA.cmake b/cmake/modules/FindLUA.cmake index 68ee4c975b..195b2f86da 100644 --- a/cmake/modules/FindLUA.cmake +++ b/cmake/modules/FindLUA.cmake @@ -18,7 +18,10 @@ INCLUDE(FindWSWinLibs) FindWSWinLibs("lua5*" "LUA_HINTS") find_package(PkgConfig) -pkg_search_module(LUA lua) +pkg_search_module(LUA lua5.2 lua-5.2 lua52 lua5.1 lua-5.1 lua51 lua5.0 lua-5.0 lua50) +if(NOT LUA_FOUND) + pkg_search_module(LUA "lua<=5.2.99") +endif() FIND_PATH(LUA_INCLUDE_DIR lua.h HINTS |