Bug 275075 - ports-mgmt/portlint: Spurious warnings
Summary: ports-mgmt/portlint: Spurious warnings
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-11-14 12:34 UTC by Jason W. Bacon
Modified: 2024-01-08 17:32 UTC (History)
2 users (show)

See Also:
fernape: maintainer-feedback? (marcus)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jason W. Bacon freebsd_committer freebsd_triage 2023-11-14 12:34:48 UTC
The following spurious warnings are generated for cad/freecad:

1) WARN: Makefile: [39]: possible direct use of command "python" found. use ${PYTHON_CMD} instead.

USES=           dos2unix compiler:c++17-lang cmake cpe gl eigen:3 fortran jpeg \
                localbase:ldflags mpi:openmpi pkgconfig python localbase qt:5 xo

Probably a failure to handle the line continuation.  You might just run the Makefile through a filter to join all continued lines before processing?

2) WARN: Makefile: no port directory /usr/ports/math/vtk found, even though it is listed in LIB_DEPENDS.

libvtksys-${VTK_VER}.so:math/vtk${VTK_VER:R}

Doesn't seem to be expanding ${VTK_VER:R}.
Comment 1 Fernando Apesteguía freebsd_committer freebsd_triage 2023-11-15 08:55:55 UTC
^Triage: Fix category
Comment 2 Joe Marcus Clarke freebsd_committer freebsd_triage 2023-11-16 16:24:58 UTC
Have a go with https://www.marcuscom.com/git/MarcusCom/portlint/commit/eca0bdab9bc6a1bdcc56256075bcc1a48d69d8ad for your first issue.  It works for me, but there may be unintended consequences.
Comment 3 Jason W. Bacon freebsd_committer freebsd_triage 2023-12-01 13:45:12 UTC
(In reply to Joe Marcus Clarke from comment #2)

Looks good so far.  I've added this patch to my wip ports:

https://github.com/outpaddling/freebsd-ports-wip

and will use it for a while for all my ports development.  I'll let you know if I come across any fallout.
Comment 4 commit-hook freebsd_committer freebsd_triage 2024-01-08 17:31:08 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=7c58302b41088e360559c3a3e58beb5cca89f521

commit 7c58302b41088e360559c3a3e58beb5cca89f521
Author:     Joe Marcus Clarke <marcus@FreeBSD.org>
AuthorDate: 2024-01-08 17:24:15 +0000
Commit:     Joe Marcus Clarke <marcus@FreeBSD.org>
CommitDate: 2024-01-08 17:30:01 +0000

    ports-mgmt/portlint: Update to 2.22

    This fixes some spurious errors by concatenating continued lines in the
    Makefile.  The downside of this is that line numbers will get more
    askew.  I thought I'd get some time to imrove this, but didn't.  And
    this fix is important to get out now.

    PR:             275075

 ports-mgmt/portlint/Makefile        | 2 +-
 ports-mgmt/portlint/src/portlint.pl | 7 ++++++-
 2 files changed, 7 insertions(+), 2 deletions(-)
Comment 5 Joe Marcus Clarke freebsd_committer freebsd_triage 2024-01-08 17:32:25 UTC
Fixed in 2.22.