Geanylua plugin error in compile in Fedora 41

Hello everyone,
I was trying to add copilot like to geany as it’s a very fast IDE, it requires geanylua plugin to be enabled, Unfortunately Official fedora Repos did remove geany-plugins-geanylua as I searched, the latest version was available for fedora 23, which is very old.
anyway I grabbed the source code from geany’s github, using ./configure --enable-geanylua
to configure and make, but ended up having lua version mismatch as following:

checking for gtk±3.0 >= 2.12
glib-2.0 >= 2.14
gio-2.0 >= 2.18
ctpl >= 0.3… no
checking for rst2html… no
checking for lua >= 5.1
lua < 5.2… no
configure: error: Package requirements (lua >= 5.1
lua < 5.2) were not met:

Package dependency requirement ‘lua < 5.2’ could not be satisfied.
Package ‘lua’ has version ‘5.4.0’, required version is ‘< 5.2’

Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.

I would appreciate any suggestion.

Fix:
using Lua Version Manager: GitHub - DhavalKapil/luaver: Lua Version Manager - Managing and switching between different versions of Lua, LuaJIT and Luarocks made easy
I managed to install lua 5.1 and then compile geanylua

thanks