Bug 59665
Summary: | rpm --whatprovides is broken | ||
---|---|---|---|
Product: | [Retired] Red Hat Linux | Reporter: | Peter Bowen <pzbowen+rhbeta> |
Component: | rpm | Assignee: | Jeff Johnson <jbj> |
Status: | CLOSED RAWHIDE | QA Contact: | |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 7.3 | CC: | chris.ricker, jbj |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | i386 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2002-03-27 17:20:14 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | |||
Bug Blocks: | 60879, 61590 |
Description
Peter Bowen
2002-02-11 17:51:50 UTC
sendmail package name-version-release, please, so I can verify what's going on, as I also suspect that some packager may have done Provides: /usr/sbin/sendmail without realizing that that is a packaging error. Meanwhile, you are confusing Provides: with contains, as in the statement The sendmail package contains /usr/bin/sendmail, but does not Provide: /usr/sbin/sendmail. That's wired into the design of rpm. So the designed syntax is rpm -qf ... /usr/sbin/sendmail not rpm -q --provides /usr/sbin/sendmail And, yes, I'm deliberately blurring the implementation in rpm so that down the road, file paths are gonna be just another form of Provides: Nope, rpm is not there yet. sendmail-8.11.6-12 redhat-lsb-1.1.0-0.2 rpm -q --provides sendmail-8.11.6-12smtpdaemon /usr/sbin/sendmail /usr/bin/mailq /usr/bin/newaliases /usr/bin/rmail /usr/share/man/man1/mailq.1.gz /usr/share/man/man1/newaliases.1.gz /usr/share/man/man5/aliases.5.gz sendmail = 8.11.6-12 Broken packaging. This is a feature request disguised as a bug report ATM. I get a lot of those. so I need to file bugs against the LPRng and sendmail packages because they provide things starting with a '/'? Dunno yet, stay tuned. Providing things starting with "/" is the right thing todo. Thanks, Florian La Roche While you may feel that providing things starting with / is the right thing to do, it does not work correctly with any released version of RPM. RPM does not support providing things that start with a /, so it is a packaging problem. This is still present in beta2, so I'm reopening, changing to beta2, and adding jbj to the CC, as he was the one that said you can't have provides starting with /. In fact, provided tokens with a '/' does "work" correctly (i.e. dependencies will be resolved) in rpm-4.0.3 but queries need to be taught to look in the Providename index if not found as a file name. Florian: while we agree that providing '/' tokens is the Right Thing to Do, the open question is "When?" and the answer AFAIK ATM is "Not now." That leads to the answer of "Broken packaging.". Still. Still seeing this with sendmail-8.12.2-8. This seems to be consistent within rawhide, so I'll close this bug now. cu, Florian La Roche This is _not_ fixed. You CAN NOT provide things starting with a "/" and expect it to work correctly. Please see jbj's last comment. This is still "broken packaging" as of sendmail-8.12.2-8. Please do not close this bug until sendmail no longer has Provide tags that start with /. So fix the problem with --whatprovides instead of squawking and send me a patch. The fix is gonna be in lib/query.c, all that's needed is to check Providename if a token starting with '/' is not found in Basenames: case RPMQV_WHATPROVIDES: if (arg[0] != '/') { mi = rpmdbInitIterator(rpmdb, RPMTAG_PROVIDENAME, arg, 0); if (mi == NULL) { rpmError(RPMERR_QUERYINFO, _("no package provides %s\n"), arg); retcode = 1; } else { retcode = showMatches(qva, mi, showPackage); } break; } /*@fallthrough@*/ case RPMQV_PATH: Fixed (by always looking in Providename, then Basenames if arg starts with '/') in rpm-4.0.4-7x.9 |