forked from pool/rpmlint
This commit is contained in:
parent
03bdc3a24b
commit
e8698f6643
@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Jun 18 14:33:09 CEST 2008 - dmueller@suse.de
|
||||
|
||||
- fix exception in tags check (bnc#399655)
|
||||
- add a warning for self-conflicts
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jun 5 19:45:10 CEST 2008 - dmueller@suse.de
|
||||
|
||||
|
@ -15,7 +15,7 @@ Name: rpmlint
|
||||
BuildRequires: rpm-python
|
||||
Summary: Rpm correctness checker
|
||||
Version: 0.82
|
||||
Release: 55
|
||||
Release: 57
|
||||
Source0: %{name}-%{version}.tar.bz2
|
||||
Source1: config
|
||||
Source1001: config.in
|
||||
@ -92,6 +92,7 @@ Patch56: fix-BinariesCheck-regex.diff
|
||||
Patch57: suse-mono-deps-checks.diff
|
||||
Patch58: add-weak-dependencies.diff
|
||||
Patch59: naming-policy-lib64.diff
|
||||
Patch60: selfconflicts-provide.diff
|
||||
%py_requires
|
||||
|
||||
%description
|
||||
@ -160,6 +161,7 @@ Authors:
|
||||
%patch57
|
||||
%patch58
|
||||
%patch59
|
||||
%patch60
|
||||
cp -p %{SOURCE1} .
|
||||
cp -p %{SOURCE2} .
|
||||
cp -p %{SOURCE3} .
|
||||
@ -198,6 +200,9 @@ rm -rf $RPM_BUILD_ROOT
|
||||
/usr/share/man/man1/rpmlint.1.gz
|
||||
|
||||
%changelog
|
||||
* Wed Jun 18 2008 dmueller@suse.de
|
||||
- fix exception in tags check (bnc#399655)
|
||||
- add a warning for self-conflicts
|
||||
* Thu Jun 05 2008 dmueller@suse.de
|
||||
- fix naming policy check for lib64 based archs (bnc#392524)
|
||||
* Wed May 14 2008 dmueller@suse.de
|
||||
|
30
selfconflicts-provide.diff
Normal file
30
selfconflicts-provide.diff
Normal file
@ -0,0 +1,30 @@
|
||||
--- TagsCheck.py
|
||||
+++ TagsCheck.py
|
||||
@@ -665,6 +665,7 @@ class TagsCheck(AbstractCheck.AbstractCheck):
|
||||
|
||||
obs=map(lambda x: x[0], pkg.obsoletes())
|
||||
provs=map(lambda x: x[0].split(':/')[0], pkg.provides())
|
||||
+ conflicts=map(lambda x: x[0].split(':/')[0], pkg.conflicts())
|
||||
reqs=map(lambda x: x[0], pkg.requires() + pkg.prereq())
|
||||
if pkg.name in obs:
|
||||
printError(pkg, 'obsolete-on-name')
|
||||
@@ -677,6 +678,8 @@ class TagsCheck(AbstractCheck.AbstractCheck):
|
||||
|
||||
useless_provides=set()
|
||||
for p in provs:
|
||||
+ if p in conflicts:
|
||||
+ printWarning(pkg,'conflicts-with-provides', p)
|
||||
if provs.count(p) != 1:
|
||||
if p not in useless_provides:
|
||||
useless_provides.add(p)
|
||||
@@ -776,6 +779,10 @@ the Release tag.''',
|
||||
'''There is no Name tag in your package. You have to specify a name using the
|
||||
Name tag.''',
|
||||
|
||||
+'conflicts-with-provides',
|
||||
+'''The same symbolic name is provided and conflicted. This package might be
|
||||
+uninstallable, if versioning matches''',
|
||||
+
|
||||
'non-coherent-filename',
|
||||
'''The file which contains the package should be named
|
||||
<NAME>-<VERSION>-<RELEASE>.<ARCH>.rpm.''',
|
@ -40,13 +40,13 @@
|
||||
+ useless_reqs.add(r)
|
||||
+ else:
|
||||
+ if r[0] != '/':
|
||||
+ printWarning(pkg, 'useless-explicit-requires', r)
|
||||
+ printWarning(pkg, 'useless-explicit-requires', r[0])
|
||||
for p in pkg.provides():
|
||||
- if string.find(p[1], '%') != -1:
|
||||
+ if string.find(p[1], '%') != -1 or string.find(p[0], '%') != -1:
|
||||
printError(pkg, 'percent-in-provides', p[0], p[1])
|
||||
+ if p[0] == pkg.name and not p[1]:
|
||||
+ printError(pkg, 'unversioned-explicit-self-provides', p)
|
||||
+ printError(pkg, 'unversioned-explicit-self-provides', p[0])
|
||||
|
||||
for c in pkg.conflicts():
|
||||
- if string.find(c[1], '%') != -1:
|
||||
|
Loading…
Reference in New Issue
Block a user