Package: linda Version: 0.3.16 Severity: wishlist Tags: patch Many /usr/share/doc/<package>/README files contain installation instructions that are not appropriate for Debian, i.e. ./configure && make && make install. The attached test warns about "./configure" in the README{,.gz} file.
import gzip import re from linda import libchecks, checks
class ReadmeCheck(libchecks.LindaChecker): 'Checks the upstream README file' def check_binary_2(self): self.parse_readme() def parse_readme(self): k = None readme = os.path.join(self.information['dir'], 'unpacked/usr/share/doc', self.pkg_name, 'README') readmegz = os.path.join(self.information['dir'], 'unpacked/usr/share/doc', self.pkg_name, 'README.gz') if os.path.exists(readme): f = open(readme) elif os.path.exists(readmegz): f = gzip.open(readmegz) k = f.read() f.close() if k: configure = re.compile(r'\./configure') if not self.pkg_name.endswith('-dev') \ and re.search(configure, k): self.signal_error('readme-contains-make-instructions') del k checks.register(ReadmeCheck)
Tag: readme-contains-make-instructions Type: Warning