forked from pool/rpmlint
Accepting request 536288 from devel:openSUSE:Factory:rpmlint
- adding connman (bsc#1057697) - add 0001-Accept-python-abi-as-a-valid-versioned-python-depend.patch - refresh 0001-Improve-XDG-Menu-checks-stability.patch (bsc#1063371) OBS-URL: https://build.opensuse.org/request/show/536288 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/rpmlint?expand=0&rev=283
This commit is contained in:
commit
718dadd572
@ -0,0 +1,33 @@
|
||||
From 534ce885e7a1529e0729dc0ae3ef75a64324583b Mon Sep 17 00:00:00 2001
|
||||
From: Dirk Mueller <dirk@dmllr.de>
|
||||
Date: Sat, 21 Oct 2017 19:24:09 +0200
|
||||
Subject: [PATCH] Accept python(abi) as a valid versioned python dependency
|
||||
|
||||
On (open)SUSE the build environment properly generates a
|
||||
requires python(abi) = x.y, so accept that to silence the warning.
|
||||
---
|
||||
FilesCheck.py | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/FilesCheck.py b/FilesCheck.py
|
||||
index abb3fa7..2ece474 100644
|
||||
--- a/FilesCheck.py
|
||||
+++ b/FilesCheck.py
|
||||
@@ -717,10 +717,10 @@ class FilesCheck(AbstractCheck.AbstractCheck):
|
||||
|
||||
if not python_dep_error:
|
||||
res = python_regex.search(f)
|
||||
- if res and not (pkg.check_versioned_dep('python-base',
|
||||
- res.group(1)) or
|
||||
- pkg.check_versioned_dep('python',
|
||||
- res.group(1))):
|
||||
+ if (res and not
|
||||
+ any((pkg.check_versioned_dep(dep, res.group(1))
|
||||
+ for dep in (
|
||||
+ 'python', 'python-base', 'python(abi)')))):
|
||||
printError(pkg, 'no-dependency-on', 'python-base',
|
||||
res.group(1))
|
||||
python_dep_error = True
|
||||
--
|
||||
2.14.2
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 3df5fd9507215cf70a1147ea631cf061475c7b34 Mon Sep 17 00:00:00 2001
|
||||
From e6594808fdf6c1fcb4175c523582ab7c358839f0 Mon Sep 17 00:00:00 2001
|
||||
From: Dirk Mueller <dirk@dmllr.de>
|
||||
Date: Fri, 29 Sep 2017 09:12:33 +0200
|
||||
Subject: [PATCH] Improve XDG Menu checks stability
|
||||
@ -7,8 +7,12 @@ Running RawConfigParser on untrusted input can cause a lot
|
||||
of exceptions. Handle them gracefully and raise appropriate
|
||||
rpmlint errors. Also separate the code a little and cleaning it up.
|
||||
---
|
||||
MenuXDGCheck.py | 76 ++++++++++++++++++++++++++++++++++++++++-----------------
|
||||
1 file changed, 53 insertions(+), 23 deletions(-)
|
||||
MenuXDGCheck.py | 84 ++++++++++++++++++++++++++----------
|
||||
test/binary/menuxdg1-0-0.noarch.rpm | Bin 0 -> 6555 bytes
|
||||
test/test_menuxdg.py | 17 ++++++++
|
||||
3 files changed, 78 insertions(+), 23 deletions(-)
|
||||
create mode 100644 test/binary/menuxdg1-0-0.noarch.rpm
|
||||
create mode 100644 test/test_menuxdg.py
|
||||
|
||||
Index: rpmlint-rpmlint-1.10/MenuXDGCheck.py
|
||||
===================================================================
|
||||
@ -33,28 +37,36 @@ Index: rpmlint-rpmlint-1.10/MenuXDGCheck.py
|
||||
|
||||
|
||||
class MenuXDGCheck(AbstractCheck.AbstractFilesCheck):
|
||||
@@ -27,6 +27,43 @@ class MenuXDGCheck(AbstractCheck.Abstrac
|
||||
@@ -27,6 +27,51 @@ class MenuXDGCheck(AbstractCheck.Abstrac
|
||||
AbstractCheck.AbstractFilesCheck.__init__(
|
||||
self, "MenuXDGCheck", r"(?:/usr/share|/etc/opt/.*/share|/opt/.*)/applications/.*\.desktop$")
|
||||
|
||||
+ def parse_desktop_file(self, pkg, root, f, filename):
|
||||
+ cfp = cfgparser.RawConfigParser()
|
||||
+ try:
|
||||
+ cfp.read(f)
|
||||
+ with open(f) as inputf:
|
||||
+ cfp.readfp(inputf, filename)
|
||||
+ except cfgparser.DuplicateSectionError as e:
|
||||
+ printError(
|
||||
+ pkg, 'desktopfile-duplicate-section', filename,
|
||||
+ '[%s]' % e.section)
|
||||
+ except cfgparser.DuplicateOptionError as e:
|
||||
+ printError(
|
||||
+ pkg, 'desktopfile-duplicate-option', filename,
|
||||
+ '[%s]/%s' % (e.section, e.option))
|
||||
+ except cfgparser.MissingSectionHeaderError:
|
||||
+ printError(
|
||||
+ pkg, 'desktopfile-missing-header', filename)
|
||||
+ except (cfgparser.ParsingError, UnicodeDecodeError) as e:
|
||||
+ except cfgparser.Error as e:
|
||||
+ # Only in Python >= 3.2
|
||||
+ if (hasattr(cfgparser, 'DuplicateOptionError') and
|
||||
+ isinstance(e, cfgparser.DuplicateOptionError)):
|
||||
+ printError(
|
||||
+ pkg, 'desktopfile-duplicate-option', filename,
|
||||
+ '[%s]/%s' % (e.section, e.option))
|
||||
+ else:
|
||||
+ printWarning(
|
||||
+ pkg, 'invalid-desktopfile', filename,
|
||||
+ e.message.partition(':')[0])
|
||||
+ except UnicodeDecodeError as e:
|
||||
+ printWarning(
|
||||
+ pkg, 'invalid-desktopfile', filename)
|
||||
+ pkg, 'invalid-desktopfile', filename, 'No valid Unicode')
|
||||
+ else:
|
||||
+ binary = None
|
||||
+ if cfp.has_option('Desktop Entry', 'Exec'):
|
||||
@ -77,7 +89,7 @@ Index: rpmlint-rpmlint-1.10/MenuXDGCheck.py
|
||||
def check_file(self, pkg, filename):
|
||||
root = pkg.dirName()
|
||||
f = root + filename
|
||||
@@ -43,25 +80,7 @@ class MenuXDGCheck(AbstractCheck.Abstrac
|
||||
@@ -43,25 +88,7 @@ class MenuXDGCheck(AbstractCheck.Abstrac
|
||||
if not is_utf8(f):
|
||||
printError(pkg, 'non-utf8-desktopfile', filename)
|
||||
|
||||
@ -104,7 +116,7 @@ Index: rpmlint-rpmlint-1.10/MenuXDGCheck.py
|
||||
|
||||
|
||||
check = MenuXDGCheck()
|
||||
@@ -76,4 +95,15 @@ addDetails(
|
||||
@@ -76,4 +103,15 @@ addDetails(
|
||||
'desktopfile-without-binary',
|
||||
'''the .desktop file is for a file not present in the package. You
|
||||
should check the requires or see if this is not a error''',
|
||||
|
9
config
9
config
@ -1022,7 +1022,12 @@ setOption("DBUSServices.WhiteList", (
|
||||
"nm-l2tp-service.conf",
|
||||
# fwupd (bsc#932807)
|
||||
"org.freedesktop.fwupd.conf",
|
||||
"org.freedesktop.fwupd.service"
|
||||
"org.freedesktop.fwupd.service",
|
||||
# connman (bsc#1057697)
|
||||
"connman-nmcompat.conf",
|
||||
"connman.conf",
|
||||
"connman-vpn-dbus.conf",
|
||||
"net.connman.vpn.service"
|
||||
))
|
||||
|
||||
setOption("PAMModules.WhiteList", (
|
||||
@ -1360,7 +1365,7 @@ addFilter(' non-devel-buildrequires recode')
|
||||
# Too noisy, and usually not something downstream packagers can fix
|
||||
addFilter(' incorrect-fsf-address ')
|
||||
addFilter(' no-manual-page-for-binary ')
|
||||
addFilter(' static-library-without-debuginfo /usr/lib(?:64)?/ghc-[\d\.]+/')
|
||||
addFilter(r' static-library-without-debuginfo /usr/lib(?:64)?/ghc-[\d\.]+/')
|
||||
|
||||
# the libre mess
|
||||
addFilter(r'libre(?:ssl|office|cad)[^\:]+: \w: shlib-policy-')
|
||||
|
@ -1,3 +1,18 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Oct 24 08:00:11 UTC 2017 - krahmer@suse.com
|
||||
|
||||
- adding connman (bsc#1057697)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Oct 21 17:26:57 UTC 2017 - dmueller@suse.com
|
||||
|
||||
- add 0001-Accept-python-abi-as-a-valid-versioned-python-depend.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Oct 16 08:58:07 UTC 2017 - dmueller@suse.com
|
||||
|
||||
- refresh 0001-Improve-XDG-Menu-checks-stability.patch (bsc#1063371)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Oct 11 08:03:12 UTC 2017 - opensuse-packaging@opensuse.org
|
||||
|
||||
|
@ -69,6 +69,7 @@ Patch48: suse-whitelist-opensuse.diff
|
||||
Patch49: extend-suse-conffiles-check.diff
|
||||
Patch50: compressed-backup-regex.diff
|
||||
Patch51: suse-speccheck-utf8.diff
|
||||
Patch52: 0001-Accept-python-abi-as-a-valid-versioned-python-depend.patch
|
||||
Patch53: suse-manpages-for-rc-scripts.diff
|
||||
Patch54: suse-ignore-specfile-errors.diff
|
||||
Patch55: invalid-filerequires.diff
|
||||
|
Loading…
Reference in New Issue
Block a user