On December 23, 2020 2:56:05 AM UTC, Michael Orlitzky <m...@gentoo.org> wrote:
>One last design issue that I ran into during the migration.
>
>The slotted lua ebuilds install the headers into subdirectories like
>/usr/include/lua5.2, but otherwise with their upstream names. The
>libraries, on the other hand, all get installed directly to $libdir..
>but with NON-standard names like liblua5.2.a (as opposed to simply
>liblua.a).
>
>This makes it impossible to build against a specific version of Lua
>without using pkg-config. The usual way would be to add
>/usr/include/lua5.2 to the compiler's include path, and $libdir/lua5.2
>to its library path (via -I and -L)... but there's no way to tell the
>build system to look for a library of an entirely different name.
>Things
>like AC_SEARCH_LIBS are going to try -llua, and that's it.
I think what you are looking for is lua_get_shared_lib() from lua-utils.eclass.
We have already got ebuilds in the tree which use it.
--
MS