Bug 231870 - ports-mgmt/portlint: Bogus warnings about extra items placed in the USES/USE_x section
Summary: ports-mgmt/portlint: Bogus warnings about extra items placed in the USES/USE_...
Status: Closed Feedback Timeout
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Joe Marcus Clarke
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-10-01 23:37 UTC by Tobias Kortkamp
Modified: 2019-07-08 16:50 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tobias Kortkamp freebsd_committer 2018-10-01 23:37:25 UTC
With something like (see editors/ghostwriter for an example port)

USES=		...
USE_GITHUB=	yes
GH_ACCOUNT=	blabla

portlint -AC wrongly complains

    WARN: Makefile: extra item placed in the USES/USE_x section, for example, "GH_ACCOUNT".
    0 fatal errors and 1 warning found.

This is contrary to what's suggested in the Porter's Handbook [1]
where it says

    Keep related variables close together.  For example, if using
    USE_GITHUB, always put the GH_* variables right after it.

Also see the example Makefile at [2].

[1] https://www.freebsd.org/doc/en/books/porters-handbook/porting-order-uses.html
[2] https://www.freebsd.org/doc/en/books/porters-handbook/porting-samplem.html
Comment 1 Joe Marcus Clarke freebsd_committer 2018-10-13 15:13:13 UTC
This is fixed in my CVS repo pending the next release.
Comment 2 Joe Marcus Clarke freebsd_committer 2018-10-13 15:40:15 UTC
Fixed in 2.18.5.
Comment 3 Tobias Kortkamp freebsd_committer 2018-10-16 08:03:49 UTC
(In reply to Joe Marcus Clarke from comment #2)
Thank you, but this fixes only the USE_GITHUB case.

It really was just an example, portlint should also not complain
about USE_PYTHON grouped with related variables, for example,

	USE_PYTHON=	...
	PYSETUP=	...

or USE_WX and related variables, for example,

	USE_WX=		...
	WX_COMPS=	...

or any other USE_x grouped with related variables.

See graphics/py-sk1 or graphics/py-gd for example ports where
portlint still just complains about this.
Comment 4 Tobias Kortkamp freebsd_committer 2018-10-20 09:23:57 UTC
Other examples are ports (graphics/gcolor3, textproc/yodl, ...) using
USE_GITLAB and the GL_* variables.