Bug 231870

Summary: ports-mgmt/portlint: Bogus warnings about extra items placed in the USES/USE_x section
Product: Ports & Packages Reporter: Tobias Kortkamp <tobik>
Component: Individual Port(s)Assignee: Joe Marcus Clarke <marcus>
Status: Closed Feedback Timeout    
Severity: Affects Only Me    
Priority: ---    
Version: Latest   
Hardware: Any   
OS: Any   
See Also: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=234527
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=239045

Description Tobias Kortkamp freebsd_committer freebsd_triage 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 freebsd_triage 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 freebsd_triage 2018-10-13 15:40:15 UTC
Fixed in 2.18.5.
Comment 3 Tobias Kortkamp freebsd_committer freebsd_triage 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 freebsd_triage 2018-10-20 09:23:57 UTC
Other examples are ports (graphics/gcolor3, textproc/yodl, ...) using
USE_GITLAB and the GL_* variables.