Bug 254797 - pkgbase: -dev packages with names containing '_' have incorrect dependencies.
Summary: pkgbase: -dev packages with names containing '_' have incorrect dependencies.
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: misc (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: Mark Johnston
URL:
Keywords:
: 239806 (view as bug list)
Depends on:
Blocks:
 
Reported: 2021-04-05 16:08 UTC by beldin
Modified: 2022-04-13 19:38 UTC (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description beldin 2021-04-05 16:08:53 UTC
When installing all self-built packages Im getting the following messages:

pkg: FreeBSD-libcompiler_rt-dev has a missing dependency: FreeBSD-libcompiler-rt
pkg: FreeBSD-libcompiler_rt-dev-lib32 has a missing dependency: FreeBSD-libcompiler-rt-dev
pkg: FreeBSD-libcompiler_rt-lib32 has a missing dependency: FreeBSD-libcompiler-rt
pkg: FreeBSD-libthread_db-dev has a missing dependency: FreeBSD-libthread-db
pkg: FreeBSD-libthread_db-dev-lib32 has a missing dependency: FreeBSD-libthread-db-dev
pkg: FreeBSD-libthread_db-lib32 has a missing dependency: FreeBSD-libthread-db

It seems the packages with '_' in their name are having their automatic dependencies generated with the '_'s turned to '-'s. (Lines 34-96 of release/packages/generate-ucl.sh seems to be the relevant area.)
Comment 1 Ed Maste freebsd_committer freebsd_triage 2022-04-11 20:58:39 UTC
Just discovered this commit:

commit 09d83a060f37ba17b29c0e90f3a0e9aa9c735592
Author: Mark Johnston <markj@FreeBSD.org>
Date:   Mon Apr 26 15:15:31 2021 -0400

    pkgbase: Remove package name mangling in generate-ucl.sh
    
    The mangling was present in the initial revision of the script, but its
    purpose is not clear.  It may have been to avoid defining make(1)
    variables with a dash in the name, but this is permitted.  Furthermore,
    it results in invalid dependency information if a dependency's name
    contains an underscore, causing e.g., libcompiler_rt-dev to depend on
    libcompiler-rt, and resulting in warnings when installing base system
    packages.  Remove the mangling.
    
    Reviewed by:    manu
    MFC after:      2 months
    Sponsored by:   The FreeBSD Foundation
    Differential Revision:  https://reviews.freebsd.org/D29883

 release/packages/generate-ucl.sh | 29 ++++++++++++-----------------
 1 file changed, 12 insertions(+), 17 deletions(-)
Comment 2 Mark Johnston freebsd_committer freebsd_triage 2022-04-11 21:33:59 UTC
(In reply to Ed Maste from comment #1)
Ah, this bug is exactly the problem I was trying to fix there.
Comment 3 Ed Maste freebsd_committer freebsd_triage 2022-04-11 23:06:33 UTC
And in stable/13,

commit 3b09235bea3f15e8f2ec883057c861c3326e7e04
Author: Mark Johnston <markj@FreeBSD.org>
Date:   Mon Apr 26 15:15:31 2021 -0400

    pkgbase: Remove package name mangling in generate-ucl.sh
    
    The mangling was present in the initial revision of the script, but its
    purpose is not clear.  It may have been to avoid defining make(1)
    variables with a dash in the name, but this is permitted.  Furthermore,
    it results in invalid dependency information if a dependency's name
    contains an underscore, causing e.g., libcompiler_rt-dev to depend on
    libcompiler-rt, and resulting in warnings when installing base system
    packages.  Remove the mangling.
    
    Reviewed by:    manu
    MFC after:      2 months
    Sponsored by:   The FreeBSD Foundation
    Differential Revision:  https://reviews.freebsd.org/D29883
    
    (cherry picked from commit 09d83a060f37ba17b29c0e90f3a0e9aa9c735592)
Comment 4 Martin 2022-04-13 19:32:58 UTC
This is about the same topic: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=239806#c4
so, when the problem is fixed, that ticket can be closed too.
Comment 5 Mark Johnston freebsd_committer freebsd_triage 2022-04-13 19:38:22 UTC
(In reply to Martin from comment #4)
Thanks for the pointer.  The problem is already fixed, so I'll close the other PR as a duplicate.
Comment 6 Mark Johnston freebsd_committer freebsd_triage 2022-04-13 19:38:27 UTC
*** Bug 239806 has been marked as a duplicate of this bug. ***