Bug 483196 - missing tags are not reported
missing tags are not reported
Status: CLOSED NEXTRELEASE
Product: Fedora
Classification: Fedora
Component: rpmlint (Show other bugs)
10
All Linux
high Severity medium
: ---
: ---
Assigned To: Ville Skyttä
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-01-30 01:46 EST by David Tardon
Modified: 2009-04-09 12:18 EDT (History)
3 users (show)

See Also:
Fixed In Version: 0.87-1.fc10
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-04-06 16:26:00 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
docbook-dtds specfile with most of tags removed (74.22 KB, application/octet-stream)
2009-01-30 01:46 EST, David Tardon
no flags Details

  None (edit)
Description David Tardon 2009-01-30 01:46:02 EST
Created attachment 330439 [details]
docbook-dtds specfile with most of tags removed

Description of problem:
rpmlint doesn't check for missing tags. When I remove some tags from a specfile, it should shout something is missing. Instead, it just finishes the control as if the specfile was without errors. I'm attaching modified docbook-dtds specfile from which I got the result mentioned under Actual results.

Version-Release number of selected component (if applicable):
rpmlint-0.85-2.fc10.noarch

How reproducible:
always

Steps to Reproduce:
1. grab SRPM of some package
2. unpack it
3. remove various tags from it's specfile
4. rpmlint *.spec
  
Actual results:
0 packages and 1 specfiles checked; 0 errors, 0 warnings.

Expected results:
Something like:
'Name is missing
Version is missing
...'

Additional info:
Comment 1 Ville Skyttä 2009-01-30 13:29:53 EST
rpm/rpmbuild does these checks itself:

$ rpmbuild -bb ~/Download/docbook-dtds.spec
error: Name field must be present in package: (main package)
error: Version field must be present in package: (main package)
error: Release field must be present in package: (main package)
error: Summary field must be present in package: (main package)
error: Group field must be present in package: (main package)
error: License field must be present in package: (main package)

It doesn't make much sense to reimplement those checks in rpmlint.  It could however run "rpm -q --qf= --specfile foo.spec" and pass through error messages if any, I'll look into this.

However, even if this is implemented, note that specfile checks in rpmlint are a small subset of available checks and it's likely to remain that way.  For more coverage, build source and binary rpms and run rpmlint against them.
Comment 2 Ville Skyttä 2009-01-30 13:37:43 EST
(See CAVEATS in rpmlint(1) man page)
Comment 3 Ville Skyttä 2009-02-04 15:31:39 EST
Done upstream, will most likely be included in 0.86:
http://rpmlint.zarb.org/cgi-bin/trac.cgi/changeset/1530

$ ./devel-rpmlint.sh ~/Download/docbook-dtds.spec
/home/scop/Download/docbook-dtds.spec: E: specfile-error error: Name field must be present in package: (main package)
/home/scop/Download/docbook-dtds.spec: E: specfile-error error: Version field must be present in package: (main package)
/home/scop/Download/docbook-dtds.spec: E: specfile-error error: Release field must be present in package: (main package)
/home/scop/Download/docbook-dtds.spec: E: specfile-error error: Summary field must be present in package: (main package)
/home/scop/Download/docbook-dtds.spec: E: specfile-error error: Group field must be present in package: (main package)
/home/scop/Download/docbook-dtds.spec: E: specfile-error error: License field must be present in package: (main package)
/home/scop/Download/docbook-dtds.spec: E: specfile-error error: query of specfile /home/scop/Download/docbook-dtds.spec failed, can't parse
0 packages and 1 specfiles checked; 7 errors, 0 warnings.
Comment 4 Fedora Update System 2009-03-19 19:29:27 EDT
rpmlint-0.87-1.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/rpmlint-0.87-1.fc10
Comment 5 Fedora Update System 2009-03-19 19:30:54 EDT
rpmlint-0.87-1.fc9 has been submitted as an update for Fedora 9.
http://admin.fedoraproject.org/updates/rpmlint-0.87-1.fc9
Comment 6 Fedora Update System 2009-03-23 11:56:22 EDT
rpmlint-0.87-1.fc10 has been pushed to the Fedora 10 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update rpmlint'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2009-2946
Comment 7 Fedora Update System 2009-04-06 16:25:30 EDT
rpmlint-0.87-1.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 8 Fedora Update System 2009-04-09 12:18:25 EDT
rpmlint-0.87-1.fc9 has been pushed to the Fedora 9 stable repository.  If problems still persist, please make note of it in this bug report.

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