Bug 273804 - mail/claws-mail-notification: claws-mail-notification is missing a required shared library: libcanberra-gtk3.so.0
Summary: mail/claws-mail-notification: claws-mail-notification is missing a required s...
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: Juraj Lutter
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-09-14 20:54 UTC by Ivan Rozhuk
Modified: 2023-09-21 06:56 UTC (History)
5 users (show)

See Also:
portmaster: maintainer-feedback+


Attachments
update to: mail_claws-mail-noticications (564 bytes, patch)
2023-09-16 00:06 UTC, Chris Hutchinson
no flags Details | Diff
update (version 2) for: mail/claws-mail-notifications (743 bytes, patch)
2023-09-16 05:58 UTC, Chris Hutchinson
no flags Details | Diff
Fix dependency on GTK version for Notification plugin (782 bytes, patch)
2023-09-16 07:32 UTC, bsd
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ivan Rozhuk 2023-09-14 20:54:56 UTC
links with libcanberra-gtk3.so.0 if audio/libcanberra-gtk3 installed, but this is not reflected in deps list.
Comment 1 Ivan Rozhuk 2023-09-15 19:51:59 UTC
As I see Makefile contains:
LIB_DEPENDS=	libcanberra-gtk.so:audio/libcanberra-gtk2 \

But I use GTK3 and it should be like:
LIB_DEPENDS=	libcanberra-gtk3.so:audio/libcanberra-gtk3 \
Comment 2 bsd 2023-09-15 20:07:52 UTC
(In reply to Ivan Rozhuk from comment #1)
Let me look at it... from your comment it should not be hard to fix it, some time necessary for testing (somehow late here just now).
Comment 3 Ivan Rozhuk 2023-09-15 20:10:46 UTC
Thanks!

PS: why not convert all claws plugins into claws-mail options?
It will be easy to maintain one port.
Comment 4 bsd 2023-09-15 20:17:23 UTC
(In reply to Ivan Rozhuk from comment #3)
Plugins are separate ports because some of them needs additional dependencies. It would be probably hard or impossible to maintain dependency chain properly. Also package builder's job would be not easy to adjust (which options should be default on and why?) - I think it is a bit more complicated, but easier maintainable, actually.
Comment 5 Chris Hutchinson 2023-09-16 00:06:31 UTC
Created attachment 244910 [details]
update to: mail_claws-mail-noticications

Thank you both for your attention to this. Please try the attached
git diff and report your findings. There's no reason to think it
won't work. But I'd love to get someone elses experience(s) befoire
committing. :-)

Thanks again!

--Chris
Comment 6 Ivan Rozhuk 2023-09-16 00:09:12 UTC
It will work, but for users like me, who use GTK3.
What about GTK2 users of port?
Comment 7 bsd 2023-09-16 05:03:33 UTC
(In reply to Ivan Rozhuk from comment #6)
In my eyes it is just a temporary solution for you, local modification. .if is needed in Makefile, at the moment, I see a chicken and egg problem there, I plan to experiment a bit now. Stay tuned :)
Comment 8 bsd 2023-09-16 05:05:38 UTC
(In reply to bsd from comment #7)
Even so, it is qorth to test it so we know this change resolves dependency chain isuue you spot.
Comment 9 Chris Hutchinson 2023-09-16 05:58:14 UTC
Created attachment 244918 [details]
update (version 2) for: mail/claws-mail-notifications

Right. Sorry. Too big a hurry to get my Friday night started. ;-)
The attached git diff should address that.

--Chris
Comment 10 Ivan Rozhuk 2023-09-16 06:06:31 UTC
(In reply to Chris Hutchinson from comment #9)

I ask about single port with many options instead of multiple port because I have no idea how to grab GTK option from parent port to make patch to this issue :)

Also I am not sure that this will work if GTK version in plugin will be differ than claws-mail.

Thanks for solution, I will test it.
Comment 11 Ivan Rozhuk 2023-09-16 06:31:38 UTC
(In reply to Ivan Rozhuk from comment #10)

Patch works for me.
Comment 12 bsd 2023-09-16 06:58:52 UTC
(In reply to Ivan Rozhuk from comment #10)
Don't hurry :) In my eyes, the proper way is take GTK version from master port. I found a way to do this, I just need to test it. Wait a bit, coming soon...
Comment 13 Chris Hutchinson 2023-09-16 07:04:02 UTC
(In reply to bsd from comment #12)
It's easy enough to place it within the master port along
with the GTK option already there.

--Chris
Comment 14 bsd 2023-09-16 07:32:56 UTC
Created attachment 244923 [details]
Fix dependency on GTK version for Notification plugin

Please test, this patch takes GTK version from master port and adjust plugin's dependencies accordingly. It was just quickly build tested for both GTK2 and GTK3 version, so more testing is in place, but building proceeded the right way, so proper libcanberra-gtk port is installed.
Comment 15 bsd 2023-09-16 07:37:30 UTC
(In reply to Chris Hutchinson from comment #13)
Integrate the plugin into master port? In my eyes, absolutely the wrong way, pkg users would be badly affected, either those who want the plugin or those who don't would be forced to build it from port... which the slave plugin port eliminates. They just install slave port if they want the plugin, nothing more. (Caveat: not tested actually by me, I do all ports by making them, but that's the logic of using pkg, as I understand it, even if I could be wrong.)
Comment 16 Chris Hutchinson 2023-09-16 18:08:21 UTC
(In reply to bsd from comment #15)
I was talking and/oring it: ||
as a conditional based upon whether the plugin was involved,
and which (GTK) version was chosen.

I tried the method you posted last night, but received an
error.
Comment 17 bsd 2023-09-16 18:35:09 UTC
(In reply to Chris Hutchinson from comment #16)
Could you show a log of failed test? I did test it for both GTK2 and GTK3 case locally, (four builds, actually, with some modification) and everything went through smoothly. Maybe some options I did not try or something...
Comment 18 Chris Hutchinson 2023-09-19 14:22:10 UTC
Comment on attachment 244923 [details]
Fix dependency on GTK version for Notification plugin

I'm going to approve this. The error I received was
from a dirty env in the jail I was testing in (false alarm).
Please commit.

Thanks to everyone that participated!

--Chris
Comment 19 commit-hook freebsd_committer freebsd_triage 2023-09-21 05:17:45 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=94535f4e72c09bc7fbd0efdfe3e7df06981da676

commit 94535f4e72c09bc7fbd0efdfe3e7df06981da676
Author:     Ivan Rozhuk <rozhuk.im@gmail.com>
AuthorDate: 2023-09-21 05:14:15 +0000
Commit:     Juraj Lutter <otis@FreeBSD.org>
CommitDate: 2023-09-21 05:14:15 +0000

    mail/claws-mail-notification: Fix RUN_DEPENDS with GTK3

    claws-mail-notification was missing a required shared library:
    libcanberra-gtk3.so.0

    PR:             273804

 mail/claws-mail-notification/Makefile | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)
Comment 20 Juraj Lutter freebsd_committer freebsd_triage 2023-09-21 06:56:18 UTC
Committed, thanks.