pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/57206: pkg_alternatives fails very late on broken ALTERNATIVES



>Number:         57206
>Category:       pkg
>Synopsis:       pkg_alternatives fails very late on broken ALTERNATIVES
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Jan 31 01:55:00 +0000 2023
>Originator:     Taylor R Campbell
>Release:        current
>Organization:
The NetBSD Alternative
>Environment:
being frozen^Wfried in carbonite
>Description:
lang/guile18 has bin/guild in ALTERNATIVES, but not in PLIST.  Attempting to register it with `pkg_alternatives rebuild' fails:

pkg_alternatives: the alternative `/pkg/2022Q4/guile/1.8/bin/guild' is not an executable

This causes pkg_alternatives to stop in the middle, so I wound up with bin/go but not bin/python3.

Fixing lang/guile18 is easy, but this infrastructure is fragile.

1. The package should fail to build if ALTERNATIVES doesn't match the package's PLIST so we detect this mistake early.  (It has been lurking in lang/guile18 since March 2022.)

2. Perhaps `pkg_alternatives rebuild' should try to reregister _all_ the packages' alternatives, and then, once done trying to register all packages, fail if any of them failed.
>How-To-Repeat:
1. Install guile18.
2. Install python310.
3. Install pkg_alternatives.
4. Try to run python3 -- fail.
>Fix:
Yes please!



Home | Main Index | Thread Index | Old Index