Bug 132011 - rpm arch-specific query output is inconsistant
Summary: rpm arch-specific query output is inconsistant
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: rpm
Version: 3.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jeff Johnson
QA Contact: Mike McLean
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-09-07 20:59 UTC by Joshua Jensen
Modified: 2007-11-30 22:07 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2004-09-08 01:01:50 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Joshua Jensen 2004-09-07 20:59:29 UTC
Description of problem:

#I have one kernel package installed
[jjensen@asic-amd32 jjensen]$ rpm -q kernel --qf '%{name}\t%{arch}\n'
kernel  x86_64

#I ask about a non-existant kernel
[jjensen@asic-amd32 jjensen]$ rpm -ql kernel.i789
package kernel.i789 is not installed

#I ask about another non-existant kernel
[jjensen@asic-amd32 jjensen]$ rpm -ql kernel.i386
(nothing showing for an error)

Isn't that inconsistant?  I can't get any error messages for the query
of a non-existant package.

Furthermore, rpm isn't even throwing an error code:

[jjensen@asic-amd32 jjensen]$ rpm -ql kernel.i386 &&  echo xyz
xyz



Version-Release number of selected component (if applicable):

rpm-4.2.1-4.4

Comment 1 Jeff Johnson 2004-09-08 01:01:50 UTC
rpm trims known tokens from the tail of the arg iff recognised.

The string ".i386" is recognised, and hence trimmed.

The string ".i789" is not recognized, and hence not trimmed.

Retrofitting an .arch marker can/will collide with, say, a
package named "kernel.i386".

Don't do that is about all I can suggest. There are no easy answers
to retrofiiting new, multilib peculier, token parsers.




Note You need to log in before you can comment on or make changes to this bug.