miconda left a comment (kamailio/kamailio#4578)
> Well, this can already be done by just providing the `-DLua_INCLUDE_DIR`, why
> would we want to introduce more params? This is more of an advanced option
> either way. You have to provide the path and not just the version which is a
> bit of a hassle, but do we need mix params? what if someone adds both
> `Lua_INCLUDE_DIR` and `USE_LUA_VERSION`?
If feels more natural to tell what Lua version to link with, rather searching
and figuring out where the include directory for desired version is. It might
not be the same path on different distributions (e.g., iirc, even kamailio
installs modules in different folders when comparing debian/ubuntu with
fedora/redhat), so I think that from documentation point of view is more
coherent, and since `find_package()` has a parameter for the version, it seems
like expected way for cmake and installed packages.
The variant with include dir seems more for the case when lua is installed from
sources/not in a standard way. From a non-developer perspective, but
voip/sysadmin, it might not be straightforward to spot include/library files. I
could be wrong, just my feeling ...
> Regarding compilation of the same module, we can create just another
> `add_library(app_lua5.x)` with the same sources and provide whatever
> compilation and linking they need. We might be able to auto-discover the
> available versions somehow and provide the relevant target only if found i
> guess.
Probably all files of app_lua module have to be freshly recompiled, not only
linked with the lua library versions on different c/make targets.
I don't consider compiling with all installed lua library versions that useful,
as a need for a Kamailio deployment, only one is wanted. But rather have a way
for the packager to compile and create packages for each lua library versions
that is considered useful to ship for a Linux distribution, so a user has the
chance to install the package shipping the module linked with the desired lua
version.
Anyhow, we can leave this for now, maybe thinking more about it in background
can bring some useful ideas.
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/4578#issuecomment-3859742770
You are receiving this because you commented.
Message ID: <kamailio/kamailio/issues/4578/[email protected]>
_______________________________________________
Kamailio - Development Mailing List -- [email protected]
To unsubscribe send an email to [email protected]
Important: keep the mailing list in the recipients, do not reply only to the
sender!