On 2017/01/22 16:50, Edd Barrett wrote:
> Hi,
> 
> On Thu, Jan 19, 2017 at 10:07:30PM +0100, Jeremie Courreges-Anglas wrote:
> > > It seems to build for all the lua versions we support, so good :)
> > 
> > This is often not enough: pure lua builds typically don't run the code
> > at build time, and C lua extensions might use lua C API functions only
> > available is some lua versions, with a failure to resolve missing
> > symbols at runtime.
> 
> I've added a (minimal) test case, which seems to work for lua51-53,
> which is good :)
> 
> > >> Regarding the port: better use "lua-mpack" or "lua-libmpack" as
> > >> PKGNAME-lua, for consistency and because the lang/lua module uses this
> > >> to provide automatic support for multiple versions.
> 
> I think I got this (almost) right, but I had to jump through some hoops
> to get the lua subpackages with the right name (I think complicated by
> the fact that the lua bindings are MULTI_PACKAGES).
> 
> I have a feeling that the FULLPKGPATH-lua needs a version suffix, but
> couldn't find a satisfying way (although what I currently have doesn't
> seem to cause any superficial issues). Any ideas?
> 
> Updated tarball attached.
> 
> -- 
> Best Regards
> Edd Barrett
> 
> http://www.theunixzoo.co.uk



I think you can get rid of the FULLPKGPATH-lua and use PKGNAME-lua
instead of FULLPKGNAME-lua. And adjust TEST_DEPENDS:

$ grep PKG.*lua Makefile
PKGNAME-lua =   ${_MODLUA_PKG_PREFIX}-mpack-${V}
TEST_DEPENDS += ${PKGNAME-lua}:${FULLPKGPATH-lua}

This gives these, which seem right to me :

$ make show=FULLPKGPATH-lua
devel/libmpack,-lua
$ make show=PKGNAMES
libmpack-1.0.3 lua-mpack-1.0.3
$ make show=TEST_DEPENDS
lua-mpack-1.0.3:devel/libmpack,-lua

$ FLAVOR=lua53 make show=FULLPKGPATH-lua
devel/libmpack,-lua,lua53
$ FLAVOR=lua53 make show=PKGNAMES
libmpack-1.0.3 lua53-mpack-1.0.3-lua53
$ FLAVOR=lua53 make show=TEST_DEPENDS
lua53-mpack-1.0.3-lua53:devel/libmpack,-lua,lua53

Reply via email to