2019-01-13 15:33:18 +01:00
|
|
|
Index: rpmlint-rpmlint-1.11/PostCheck.py
|
|
|
|
===================================================================
|
|
|
|
--- rpmlint-rpmlint-1.11.orig/PostCheck.py
|
|
|
|
+++ rpmlint-rpmlint-1.11/PostCheck.py
|
|
|
|
@@ -108,20 +108,6 @@ class PostCheck(AbstractCheck.AbstractCh
|
|
|
|
pkg, files, prog[idx],
|
|
|
|
pkg.header[tag[0]][idx], tag[2], prereq)
|
2017-09-30 10:27:35 +02:00
|
|
|
|
|
|
|
- ghost_files = pkg.ghostFiles()
|
|
|
|
- if ghost_files:
|
|
|
|
- postin = pkg[rpm.RPMTAG_POSTIN]
|
|
|
|
- prein = pkg[rpm.RPMTAG_PREIN]
|
|
|
|
- for f in ghost_files:
|
|
|
|
- if f in pkg.missingOkFiles():
|
|
|
|
- continue
|
|
|
|
- if not postin and not prein:
|
|
|
|
- printWarning(pkg, 'ghost-files-without-postin')
|
|
|
|
- if (not postin or f not in postin) and \
|
|
|
|
- (not prein or f not in prein):
|
|
|
|
- printWarning(pkg,
|
|
|
|
- 'postin-without-ghost-file-creation', f)
|
|
|
|
-
|
|
|
|
def check_aux(self, pkg, files, prog, script, tag, prereq):
|
|
|
|
if script:
|
2019-01-13 15:33:18 +01:00
|
|
|
script_str = Pkg.b2s(script)
|
|
|
|
@@ -193,10 +179,6 @@ class PostCheck(AbstractCheck.AbstractCh
|
2017-09-30 10:27:35 +02:00
|
|
|
check = PostCheck()
|
|
|
|
|
|
|
|
# Add information about checks
|
|
|
|
-addDetails(
|
|
|
|
-'postin-without-ghost-file-creation',
|
|
|
|
-'''A file tagged as ghost is not created during %prein nor during %postin.''',
|
|
|
|
-)
|
2019-01-13 15:33:18 +01:00
|
|
|
for scriptlet in map(lambda x: '%' + x, Pkg.RPM_SCRIPTLETS):
|
2017-09-30 10:27:35 +02:00
|
|
|
addDetails(
|
|
|
|
'one-line-command-in-%s' % scriptlet,
|