Bug 260501 - multimedia/pipewire: drop dependency on devel/ncurses
Summary: multimedia/pipewire: drop dependency on devel/ncurses
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Jan Beich
URL:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2021-12-17 19:28 UTC by Jan Beich
Modified: 2021-12-23 10:09 UTC (History)
6 users (show)

See Also:
arrowd: maintainer-feedback+


Attachments
v1 (1.89 KB, patch)
2021-12-17 19:28 UTC, Jan Beich
no flags Details | Diff
v1.1 (1.88 KB, patch)
2021-12-17 19:35 UTC, Jan Beich
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Beich freebsd_committer freebsd_triage 2021-12-17 19:28:00 UTC
Created attachment 230205 [details]
v1

Depending on devel/ncurses is horrible as it contaminates LDFLAGS with -Wl,-rpath,${NCURSESRPATH} for ports that simply have USES=ncurses. Given base system is wishy-washy with *.pc files for bundled (e.g., bug 257158) dependencies let's just stuff Meson with something that mimics 5.9 snapshot from FreeBSD 12.2.
Comment 1 Jan Beich freebsd_committer freebsd_triage 2021-12-17 19:35:49 UTC
Created attachment 230206 [details]
v1.1

Drop -ltinfow from fake ncursesw.pc. On FreeBSD < 14 it's part of -lncursesw and garbage-collected by Meson via default -Wl,--as-needed (unless -Db_asneeded=false).
Comment 2 Dima Panov freebsd_committer freebsd_triage 2021-12-17 20:37:58 UTC
Better is push it for all consumers via ncurses.mk 'cause not only pipewire affected.
Comment 3 Gleb Popov freebsd_committer freebsd_triage 2021-12-23 08:15:48 UTC
I don't have a strong opinion on this. Jan, do you want to hack ncurses.mk, or let's just push this fix for pipewire only?
Comment 4 Jan Beich freebsd_committer freebsd_triage 2021-12-23 09:12:10 UTC
(In reply to Gleb Popov from comment #3)
> Jan, do you want to hack ncurses.mk,

No. None of my ~226 ports have USES=ncurses:port. Everything else is not my problem.
Comment 5 Gleb Popov freebsd_committer freebsd_triage 2021-12-23 09:13:12 UTC
Then feel free to push this patch, thanks.
Comment 6 commit-hook freebsd_committer freebsd_triage 2021-12-23 10:07:34 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=4f6e6d2b9a7ff48699785d10be10a67732a20622

commit 4f6e6d2b9a7ff48699785d10be10a67732a20622
Author:     Jan Beich <jbeich@FreeBSD.org>
AuthorDate: 2021-12-17 19:09:33 +0000
Commit:     Jan Beich <jbeich@FreeBSD.org>
CommitDate: 2021-12-23 10:04:53 +0000

    multimedia/pipewire: drop dependency on devel/ncurses

    Keep USES=ncurses to ensure consistency but don't require ncurses
    package as it overrides in-base version for all ports built after.

    PR:             260501
    Approved by:    arrowd (maintainer, previous version)

 multimedia/pipewire/Makefile                | 14 ++++++--------
 multimedia/pipewire/files/ncursesw.pc (new) | 10 ++++++++++
 2 files changed, 16 insertions(+), 8 deletions(-)
Comment 7 Jan Beich freebsd_committer freebsd_triage 2021-12-23 10:09:10 UTC
Landed with minor changes: Always define USES=ncurses to support transparent dependency on devel/ncurses for users who have it *already installed* (similar to USES=ssl + security/openssl). For example, clean build vs. dirty build with preinstalled ncurses (tested via Makefile.local):

$ poudriere testport -j 122amd64 multimedia/pipewire
[...]
-Run-time dependency ncursesw found: YES 5.9.20140222
+Run-time dependency ncursesw found: YES 6.3.20211021
[...]
- 0x0000000000000001 NEEDED               Shared library: [libncursesw.so.8]
+ 0x0000000000000001 NEEDED               Shared library: [libncurses.so.6]
+ 0x0000000000000001 NEEDED               Shared library: [libtinfo.so.6]