PERLLDOPTS is already used in app_perl module. Reuse this variable in db_perlvdb module instead of always setting LIBS to (shell perl -MExtUtils::Embed -e ldopts) Indeed, this will not work when cross-compiling (the value will be retrieved for the host perl and not the target perl)
Signed-off-by: Fabrice Fontaine fabrice.fontaine@orange.com You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/934
-- Commit Summary --
* Reuse PERLLDOPTS in db_perlvdb
-- File Changes --
M src/modules/db_perlvdb/Makefile (6)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/934.patch https://github.com/kamailio/kamailio/pull/934.diff
Not an app_perl user here, wrote some code for it though ...
It is not clear from the commit message: is this commit breaking the cross compilation?
What are the benefits of using the env PERLLDOPTS variable instead of computing it with `perl -MExtUtils::Embed -e ldopts`?
The commit is actually fixing the cross-compilation of the db_perlvdb module, not breaking it. Without it, this module calls perl to get the ld flags, for example -L/usr/lib which is not what you want when you cross compile as we will not find the target libraries. To find the target libraries, we have to set the PERLLDOPTS variable.
Ok, thanks for clarification. I will merge it.
Merged #934.