Page MenuHomeFreeBSD

Uses/lua.mk - add flavor support and other options
Needs ReviewPublic

Authored by andrew_tao173.riddles.org.uk on Jul 29 2018, 1:41 AM.

Details

Reviewers
None
Group Reviewers
portmgr
Summary

This is a (first attempt at) adding flavor support to USES=lua, plus some additional options.

The intent is to allow the following:

  1. Lua modules like devel/lua-stdlib-* can be changed to use flavors to keep their dependencies straight, and some helper definitions in lua.mk make it easier for them to keep their documentation subdirs separate
  2. The lang/lua ports themselves could be changed to use USES=lua:envcore,NN to centralize the definitions of all the LUA_* variables in one place, rather than duplicating them between lua.mk and lang/luaNN/Makefile
  3. Applications that use Lua probably wouldn't want to use the flavors option, but can now use LUA_FLAVOR when declaring dependencies on libs
  4. More version range options are supported, e.g. USES=lua:52-54 or USES=lua:-53

A functional change is that this version makes no attempt to look at what versions of Lua are already installed - that seems to me to be a very bad idea.

Test Plan

Needs input.

Diff Detail

Repository
rP FreeBSD ports repository
Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

Herald added a subscriber: mat. · View Herald Transcript
mat added inline comments.Aug 6 2018, 11:19 AM
Mk/Uses/lua.mk
226–230

I am not sure why this test. If you are building lang/luaXY, PORTNAME is lua anyway.

Mk/Uses/lua.mk
226–230

You're right, that's unnecessary.

Remove an unnecessary conditional as pointed out by mat.

Remove some not-very-helpful commentary.

andrew_tao173.riddles.org.uk marked 2 inline comments as done.Aug 8 2018, 9:37 PM
ygy added a subscriber: ygy.Aug 12 2018, 5:13 AM