Created attachment 240605 [details] Patch solving the problem for me When running "make all-depends-list", for some ports dependencies are not listed. For example, "make all-depends-list" on x11-wm/xfce4 includes x11-servers/xorg-server but not x11/libxcvt. For x11-servers/xorg-server, "make all-depends-list" includes x11-libxcvt. The underlying problem seems to be that Mk/Scripts/depends-list.sh sets FLAVOR, even when it is an empty string. This breaks the default flavour setting in x11-servers/xorg-server. The bug is that that the flavour shell variable is not enclosed in quotes, making the test for a non-empty string always succeed. Patch attached.
I just discovered this independently when tracking down why fetch-recursive was not fetching all dependencies; I can confirm both the diagnosis and that the fix works.
Relatedly, fetch-recursive and so on also don't handle the case where a port depends (possibly indirectly) on both foo@x and foo@y; the de-duplication logic checks only the port dir and not the flavor. Using $port_display in place of $d in the $checked variable fixes this.
I put up my version of the fix at: https://reviews.freebsd.org/D40491
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=873d4f6f9905bae3fe580e86aaebbbe994adba97 commit 873d4f6f9905bae3fe580e86aaebbbe994adba97 Author: Andrew "RhodiumToad" Gierth <andrew@tao11.riddles.org.uk> AuthorDate: 2023-06-13 20:09:59 +0000 Commit: Luca Pizzamiglio <pizzamig@FreeBSD.org> CommitDate: 2023-06-13 20:09:59 +0000 Mk/Scripts: Fix ports depends-list.sh depends-list.sh fails in two ways: one is a simple quoting bug which causes empty FLAVOR variables to be propagated; the other is that de-duplication is being done without regard for flavors. The upshot of these is that where a port depends on a specific flavor (first bug) or on multiple flavors (second bug, usually caused by build dependencies) of another port, the constructed dependency list is incomplete, and so -recursive targets do not do all the required work. (This is especially annoying for fetch-recursive.) Reviewed by: portmgr@FreeBSD.org PR: 269982 Differential Revision: https://reviews.freebsd.org/D40491 Mk/Scripts/depends-list.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
Thanks!
And thank you too!
Thanks for your contributions and sorry if it took so long!