From a560e11e916994e45cd91623e0a6a9ee020234855072b44a288a00bd6237b067 Mon Sep 17 00:00:00 2001 From: Marcus Rueckert Date: Fri, 26 Nov 2010 16:47:21 +0000 Subject: [PATCH] Accepting request 53881 from Base:System Accepted submit request 53881 from user dirkmueller OBS-URL: https://build.opensuse.org/request/show/53881 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/rpmlint?expand=0&rev=86 --- config | 1 - extend-suse-conffiles-check.diff | 11 +++++++++++ rpmlint.changes | 7 +++++++ rpmlint.spec | 2 ++ suse-no-run-ldconfig.diff | 12 +++++------- suse-pkg-config-check.diff | 14 ++++++++------ suse-url-check.diff | 23 +++++++++++------------ 7 files changed, 44 insertions(+), 26 deletions(-) create mode 100644 extend-suse-conffiles-check.diff diff --git a/config b/config index b61c324..01cc084 100644 --- a/config +++ b/config @@ -209,7 +209,6 @@ addFilter(" subsys-not-used") addFilter(" dangerous-command.*") addFilter(" setuid-binary.*") addFilter(".*FSSTND-dir-in-var /var/adm/.*") -addFilter("no-url-tag") addFilter("subdir-in-bin /sbin/conf.d/") addFilter(" invalid-license") addFilter(".* nss_db non-standard-dir-in-var db") diff --git a/extend-suse-conffiles-check.diff b/extend-suse-conffiles-check.diff new file mode 100644 index 0000000..d841278 --- /dev/null +++ b/extend-suse-conffiles-check.diff @@ -0,0 +1,11 @@ +--- FilesCheck.py ++++ FilesCheck.py +@@ -1200,7 +1200,7 @@ + if nonexec_file and not docdir_examples_regex.search(f): + printWarning(pkg, 'spurious-executable-perm', f) + elif f.startswith('/etc/') and f not in config_files and \ +- f not in ghost_files: ++ f not in ghost_files and not f.endswith(".desktop"): + printWarning(pkg, 'non-conffile-in-etc', f) + + if pkg.arch == 'noarch' and f.startswith('/usr/lib64/python'): diff --git a/rpmlint.changes b/rpmlint.changes index 8c3b556..9e82ed4 100644 --- a/rpmlint.changes +++ b/rpmlint.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed Nov 24 11:43:53 CET 2010 - dmueller@suse.de + +- remove filter for no-url-tag (bnc#642588) +- clarify wording for run_ldconfig check (bnc#637187) +- skip desktop files in /etc (bnc#604283) + ------------------------------------------------------------------- Fri Nov 19 13:23:56 CET 2010 - dmueller@suse.de diff --git a/rpmlint.spec b/rpmlint.spec index abca5ca..6dde0bc 100644 --- a/rpmlint.spec +++ b/rpmlint.spec @@ -122,6 +122,7 @@ Patch80: remove-expand-macros.diff Patch81: suse-whitelist-opensuse.diff Patch82: rpmlint-badness-info.diff Patch83: incoherent-warning-fix.diff +Patch84: extend-suse-conffiles-check.diff %py_requires %description @@ -200,6 +201,7 @@ Authors: %patch81 %patch82 -p1 %patch83 +%patch84 cp -p %{SOURCE1} . cp -p %{SOURCE2} . cp -p %{SOURCE3} . diff --git a/suse-no-run-ldconfig.diff b/suse-no-run-ldconfig.diff index 897666e..343cfe9 100644 --- a/suse-no-run-ldconfig.diff +++ b/suse-no-run-ldconfig.diff @@ -1,8 +1,6 @@ -Index: SpecCheck.py -=================================================================== ---- SpecCheck.py.orig +--- SpecCheck.py +++ SpecCheck.py -@@ -403,6 +403,10 @@ class SpecCheck(AbstractCheck.AbstractCh +@@ -394,6 +394,10 @@ printWarning(pkg, 'comparison-operator-in-deptoken', conf) @@ -13,17 +11,17 @@ Index: SpecCheck.py if current_section == 'changelog': for match in AbstractCheck.macro_regex.findall(line): res = re.match('%+', match) -@@ -690,6 +694,14 @@ may break short circuit builds.''', +@@ -681,6 +685,14 @@ '''Make check or other automated regression test should be run in %check, as they can be disabled with a rpm macro for short circuiting purposes.''', +'deprecated-use-of-%run_ldconfig', +'''According to the new SUSE Packaging Conventions, the use of %run_ldconfig -+is deprecated. use ++is deprecated. Please use /sbin/ldconfig instead, or + +%post(un) -p /sbin/ldconfig + -+instead.''', ++in the case where ldconfig is the only command to be executed.''', + 'macro-in-%changelog', '''Macros are expanded in %changelog too, which can in unfortunate cases lead diff --git a/suse-pkg-config-check.diff b/suse-pkg-config-check.diff index 231cd34..dc261dc 100644 --- a/suse-pkg-config-check.diff +++ b/suse-pkg-config-check.diff @@ -1,6 +1,8 @@ ---- TagsCheck.py +Index: TagsCheck.py +=================================================================== +--- TagsCheck.py.orig +++ TagsCheck.py -@@ -414,6 +414,7 @@ +@@ -414,6 +414,7 @@ lib_devel_number_regex = re.compile('^li invalid_url_regex = re.compile(Config.getOption('InvalidURL'), re.IGNORECASE) lib_package_regex = re.compile('(?:^(?:compat-)?lib.*?(\.so.*)?|libs?[\d-]*)$', re.IGNORECASE) leading_space_regex = re.compile('^\s+') @@ -8,7 +10,7 @@ license_regex = re.compile('\(([^)]+)\)|\s(?:and|or)\s') invalid_version_regex = re.compile('([0-9](?:rc|alpha|beta|pre).*)', re.IGNORECASE) # () are here for grouping purpose in the regexp -@@ -623,10 +624,12 @@ +@@ -623,10 +624,12 @@ class TagsCheck(AbstractCheck.AbstractCh base = is_devel.group(1) dep = None has_so = False @@ -22,7 +24,7 @@ if has_so: base_or_libs = base + '/' + base + '-libs/lib' + base # try to match *%_isa as well (e.g. "(x86-64)", "(x86-32)") -@@ -663,6 +666,15 @@ +@@ -663,6 +666,15 @@ class TagsCheck(AbstractCheck.AbstractCh if prov not in (x[0] for x in pkg.provides()): printWarning(pkg, 'no-provides', prov) @@ -38,9 +40,9 @@ # List of words to ignore in spell check ignored_words = set() for pf in pkg.files(): -@@ -1082,6 +1094,11 @@ +@@ -1082,6 +1094,11 @@ instead or require a file in bin or /etc 'no-url-tag', - '''The URL tag is missing.''', + '''The URL tag is missing. Please add a http or ftp link to the project location.''', +'no-pkg-config-provides', +'''The package installes a .pc file but does not provide pkgconfig(..) provides. diff --git a/suse-url-check.diff b/suse-url-check.diff index af959b4..1addd32 100644 --- a/suse-url-check.diff +++ b/suse-url-check.diff @@ -1,8 +1,6 @@ -Index: TagsCheck.py -=================================================================== ---- TagsCheck.py.orig +--- TagsCheck.py +++ TagsCheck.py -@@ -762,14 +762,14 @@ class TagsCheck(AbstractCheck.AbstractCh +@@ -762,7 +762,7 @@ if not valid_license: self._unexpanded_macros(pkg, 'License', rpm_license) @@ -11,11 +9,12 @@ Index: TagsCheck.py if hasattr(rpm, 'RPMTAG_%s' % tag.upper()): url = pkg[getattr(rpm, 'RPMTAG_%s' % tag.upper())] self._unexpanded_macros(pkg, tag, url, is_url = True) - if url: - (scheme, netloc) = urlparse(url)[0:2] - if not scheme or not netloc or "." not in netloc or \ -- scheme not in ('http', 'https', 'ftp') or \ -+ scheme not in ('obs', 'http', 'https', 'ftp') or \ - (Config.getOption('InvalidURL') and \ - invalid_url_regex.search(url)): - printWarning(pkg, 'invalid-url', tag, url) +@@ -1070,7 +1070,7 @@ + '''This rpm requires a specific release of another package.''', + + 'no-url-tag', +-'''The URL tag is missing.''', ++'''The URL tag is missing. Please add a http or ftp link to the project location.''', + + 'name-repeated-in-summary', + '''The name of the package is repeated in its summary. This is often redundant