Bug 255477 - x11/libfm: fix BROKEN for gtk3 flavor
Summary: x11/libfm: fix BROKEN for gtk3 flavor
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: Fernando Apesteguía
Keywords: dogfood, easy, patch, patch-ready
Depends on:
Reported: 2021-04-29 05:20 UTC by Chris Hutchinson
Modified: 2021-04-29 18:42 UTC (History)
2 users (show)

See Also:

x11/libfm: patch to fix gtk3 flavor (5.98 KB, patch)
2021-04-29 05:20 UTC, Chris Hutchinson
portmaster: maintainer-approval+
Details | Diff
x11/libfm: patch version 2 (6.43 KB, patch)
2021-04-29 07:31 UTC, Chris Hutchinson
portmaster: maintainer-approval+
Details | Diff
x11/libfm: patch (version 3) (6.44 KB, patch)
2021-04-29 07:37 UTC, Chris Hutchinson
portmaster: maintainer-approval+
Details | Diff
x11/libfm: ( version 4 ) FINAL version (1.50 KB, patch)
2021-04-29 08:25 UTC, Chris Hutchinson
portmaster: maintainer-approval+
Details | Diff
x11/libfm: GIT diff (1.53 KB, patch)
2021-04-29 08:38 UTC, Chris Hutchinson
portmaster: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Hutchinson 2021-04-29 05:20:39 UTC
Created attachment 224514 [details]
x11/libfm: patch to fix gtk3 flavor

This patch fixes the pkg-plist failure for the
gtk3 flavor of this port. pkg-fallout@ has been
reporting failures.

adds pkg-plist-gtk3

Tests AOK on 12/amd64

I attempted to provide a git diff. But the git
package installed as of today refuses to generate
a complete diff. It only produces a diff for the
changed Makefile. Even after issuing
git add pkg-plist-gtk3 and confirming git recorded
the add (git status --short). After 6hrs of trying
to make it work, I resorted to diff(1).
If I had to use git for $DAYJOB I'd commit suicide.

Thanks! :-)

Comment 1 Fernando Apesteguía freebsd_committer 2021-04-29 06:08:16 UTC
^Triage: Maintainer-feedback flag (+) not required unless requested (?) first
Comment 2 Fernando Apesteguía freebsd_committer 2021-04-29 06:33:47 UTC
Hi Chris,

I have some comments on the patch:

* In pkg-plist-gtk3, etc/xdg/libfm/libfm.conf.sample is not marked as a sample file, and files like share/locale/af/LC_MESSAGES/libfm.mo are installed regardless of %%NLS%% as opposed to pkg-plist (gtk2 flavor) Is this right?

* When FLAVOR=gtk2 then GTKVERSION=gkt and PLIST will have things like:
   include/libfm/fm-%%GTKVERSION%%-file-launcher.h, hence

That is exactly the same file that is listed in pkg-plist-gtk3 which has a hardcoded include/libfm/fm-gtk-file-launcher.h. Shouldn't it have a GTKVERSION somewhere to be replaced by gtk3 when FLAVOR=gtk3?

Comment 3 Chris Hutchinson 2021-04-29 07:06:41 UTC
(In reply to Fernando Apesteguía from comment #2)
Thank you for your attention to this, Fernando.
You're probably right. When I saw the output from
the failure on pkg-fallout@. I asked make to create
a file for the FLAVOR gtk3:

make -DBATCH FLAVOR=gtk3 makeplist

the pkg-plist-gtk3 was the result. I modified Makefile
to include the new pkg-plist for the gtk3 condifional.
Then I then started fresh with
make -DBATCH FLAVOR=gtk3 check-plist
The results were:

gmake[4]: Leaving directory '/usr/ports/x11/libfm/work-gtk3/libfm-1.3.2'
gmake[3]: Leaving directory '/usr/ports/x11/libfm/work-gtk3/libfm-1.3.2'
gmake[2]: Leaving directory '/usr/ports/x11/libfm/work-gtk3/libfm-1.3.2'
gmake[1]: Leaving directory '/usr/ports/x11/libfm/work-gtk3/libfm-1.3.2'
install  -m 0644 /usr/ports/x11/libfm/work-gtk3/libfm-1.3.2/src/actions/fm-actions.h  /usr/ports/x11/libfm/work-gtk3/stage/usr/local/include/libfm
====> Compressing man pages (compress-man)
====> Running Q/A tests (stage-qa)
====> Checking for pkg-plist issues (check-plist)
===> Parsing plist
===> Checking for items in STAGEDIR missing from pkg-plist
===> Checking for items in pkg-plist which are not in STAGEDIR
===> No pkg-plist issues found (check-plist)

Which seemed to be the correct response.

I get the same results with:
make -DBATCH check-plist
which defaults to gtk2
===> No pkg-plist issues found (check-plist)

I guess I need to take a closer look, and return gtk specific
versions in the PLIST. It's midnight here. So I'll post a new
patch with your suggested changes tomorrow (later today ;-)).

Thanks again!

Comment 4 Chris Hutchinson 2021-04-29 07:31:37 UTC
Created attachment 224515 [details]
x11/libfm: patch version 2

OK a quick look indicated it was a simple correction.
Here's version 2 which incorporates your recommendations.

Thanks! :-)

Comment 5 Chris Hutchinson 2021-04-29 07:37:58 UTC
Created attachment 224516 [details]
x11/libfm: patch (version 3)

OOPS! another check indicated I overlooked @sample.
Like I said; it's past midnight here. :P
Here's version 3. This one IS correct.
Sorry for the bother, and Thanks! :-)

Comment 6 Chris Hutchinson 2021-04-29 08:25:07 UTC
Created attachment 224520 [details]
x11/libfm: ( version 4 ) FINAL version

Sorry. It's late (1:30am) here. But something was
bothering me about this. So I had to take a closer
Turns out %%GTKVERSION%% isn't created by this port
in a couple of places (see pkg-plist changes). So I
simply removed the variable where it wasn't used, and
then the same pkg-plist can be used for both
gtk2 && gtk3.
I carefully checked against both. Builds returned:

No pkg-plist issues found (check-plist)

I think we're FINALLY done here. ;-)


Comment 7 Chris Hutchinson 2021-04-29 08:38:35 UTC
Created attachment 224521 [details]
x11/libfm: GIT diff

Here's a git diff. In case you like them better.

Comment 8 John Hein 2021-04-29 17:50:33 UTC
(In reply to Chris Hutchinson from comment #7)
+1.  I was getting the plist failures as well (was using FLAVOR=gtk3). This patch works here.
Comment 9 commit-hook freebsd_committer 2021-04-29 17:53:36 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=751545cdf6de2a9a1f18fb718906ace77d093b62

commit 751545cdf6de2a9a1f18fb718906ace77d093b62
Author:     Fernando Apesteguía <fernape@FreeBSD.org>
AuthorDate: 2021-04-29 09:02:33 +0000
Commit:     Fernando Apesteguía <fernape@FreeBSD.org>
CommitDate: 2021-04-29 17:49:40 +0000

    x11/libfm: fix BROKEN for gtk3 flavor

    PR:     255477
    Reported by:    portmaster@bsdforge.com (maintainer)

 x11/libfm/Makefile  |  1 +
 x11/libfm/pkg-plist | 16 ++++++++--------
 2 files changed, 9 insertions(+), 8 deletions(-)
Comment 10 Fernando Apesteguía freebsd_committer 2021-04-29 17:54:32 UTC


P.S: Chris, do not worry about delaying a commit a few hours, sleep deprivation is not good!
Comment 11 Chris Hutchinson 2021-04-29 18:42:10 UTC
(In reply to Fernando Apesteguía from comment #10)
Thanks, Fernando. That's probably good advice. :-)

Thanks for all the time, and energy you put into this! :-)