From 096337f7a5a5ef8bcec1589f8d78f04d920a2b35 Mon Sep 17 00:00:00 2001 From: George Kiagiadakis Date: Fri, 25 Jun 2021 18:34:25 +0300 Subject: [PATCH] meson: bump lua dependency to 5.4 and update the subproject --- meson.build | 26 +++++++++++++++++++------- subprojects/lua.wrap | 19 ++++++++++--------- 2 files changed, 29 insertions(+), 16 deletions(-) diff --git a/meson.build b/meson.build index 8005e312..d932fa21 100644 --- a/meson.build +++ b/meson.build @@ -57,15 +57,27 @@ mathlib = cc.find_library('m') threads_dep = dependency('threads') if get_option('system-lua') - lua_dep = dependency('lua', version: ['>=5.3.0', '<5.4.0'], required: false) + lua_dep = dependency('lua-5.4', required: false) + if not lua_dep.found() + lua_dep = dependency('lua5.4', required: false) + endif + if not lua_dep.found() + lua_dep = dependency('lua54', required: false) + endif + if not lua_dep.found() + lua_dep = dependency('lua-5.3', required: false) + endif if not lua_dep.found() lua_dep = dependency('lua5.3', required: false) - if not lua_dep.found() - lua_dep = dependency('lua53', required: false) - if not lua_dep.found() - lua_dep = dependency('lua-5.3', required: true , allow_fallback: false) - endif - endif + endif + if not lua_dep.found() + lua_dep = dependency('lua53', required: false) + endif + if not lua_dep.found() + lua_dep = dependency('lua', version: ['>=5.3.0'], required: false) + endif + if not lua_dep.found() + error ('Could not find lua. Lua version 5.4 or 5.3 required') endif else lua_proj = subproject('lua', default_options: ['default_library=static']) diff --git a/subprojects/lua.wrap b/subprojects/lua.wrap index f17ab50d..71a37d39 100644 --- a/subprojects/lua.wrap +++ b/subprojects/lua.wrap @@ -1,11 +1,12 @@ [wrap-file] -directory = lua-5.3.6 -source_url = https://www.lua.org/ftp/lua-5.3.6.tar.gz -source_filename = lua-5.3.6.tar.gz -source_hash = fc5fd69bb8736323f026672b1b7235da613d7177e72558893a0bdcd320466d60 -patch_url = https://wrapdb.mesonbuild.com/v1/projects/lua/5.3.6/1/get_zip -patch_filename = lua-5.3.6-1-wrap.zip -patch_hash = dd045301a56c7c1fb8d4545cadb93981fe95c44c9526cb58cc75a1b74a2c5116 +directory = lua-5.4.3 +source_url = https://www.lua.org/ftp/lua-5.4.3.tar.gz +source_filename = lua-5.4.3.tar.gz +source_hash = f8612276169e3bfcbcfb8f226195bfc6e466fe13042f1076cbde92b7ec96bbfb +patch_filename = lua_5.4.3-1_patch.zip +patch_url = https://wrapdb.mesonbuild.com/v2/lua_5.4.3-1/get_patch +patch_hash = 66794455e18d373041c8ffa9c23d1629b813c7a716f8905425d347937f5c8dc8 + +[provide] +lua-5.4 = lua_dep -[provides] -lua-5.3 = lua_dep