diff --git a/add-check-for-a-non-zero-.text-segment-in-.a-archive.patch b/add-check-for-a-non-zero-.text-segment-in-.a-archive.patch index 8e88db3..1df07d1 100644 --- a/add-check-for-a-non-zero-.text-segment-in-.a-archive.patch +++ b/add-check-for-a-non-zero-.text-segment-in-.a-archive.patch @@ -1,5 +1,5 @@ diff --git a/BinariesCheck.py b/BinariesCheck.py -index 36d73f8..8200f1b 100644 +index 36d73f8..7257ffd 100644 --- a/BinariesCheck.py +++ b/BinariesCheck.py @@ -73,6 +73,10 @@ class BinaryInfo(object): @@ -8,7 +8,7 @@ index 36d73f8..8200f1b 100644 + # [Nr] Name Type Address Off Size ES Flg Lk Inf Al + # [ 1] .text PROGBITS 0000000000000000 000040 000000 00 AX 0 0 1 -+ text_section_regex = re.compile(r'\s*\[[ 0-9]+\]\s*\.text\s*\w+\s*\w*\s*\w*\w*\s*(\w*).*.') ++ section_regex = re.compile(r'.*\] (?P
[^\s]*)\s*\w+\s*\w*\s*\w*\w*\s*(?P\w*)') + def __init__(self, pkg, path, fname, is_ar, is_shlib): self.readelf_error = False @@ -40,10 +40,10 @@ index 36d73f8..8200f1b 100644 + non_zero_text_segment = False + + for line in lines: -+ r = self.text_section_regex.search(line) -+ if r: ++ r = self.section_regex.search(line) ++ if r and r.group('section').startswith('.text'): + has_text_segment = True -+ size = int(r.group(1), 16) ++ size = int(r.group('size'), 16) + if size > 0: + non_zero_text_segment = True + if has_text_segment and not non_zero_text_segment: diff --git a/rpmlint.changes b/rpmlint.changes index 674005e..c174b27 100644 --- a/rpmlint.changes +++ b/rpmlint.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Aug 2 07:53:03 UTC 2019 - Martin Liška + +- Update add-check-for-a-non-zero-.text-segment-in-.a-archive.patch patch to align with: + https://github.com/rpm-software-management/rpmlint/commit/c59324fd68ba86c8382fe09d43f12de32d764354 + ------------------------------------------------------------------- Sun Jul 28 15:04:34 UTC 2019 - Martin Liška