From: MyungJoo Ham Date: Thu, 6 Apr 2017 04:20:26 +0000 (+0900) Subject: RULE: fix: allow %ifarch/%endif X-Git-Tag: submit/tizen/20170406.050031~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F27%2F123527%2F1;p=tools%2Fbuilding-blocks.git RULE: fix: allow %ifarch/%endif 1. Allow %ifarch/%endif in %files section 2. Make a more clear error message for RULE 5-3. Change-Id: I2f04234c8b01dd6d718ceece94643ee085081131 Signed-off-by: MyungJoo Ham --- diff --git a/rule_checker.py b/rule_checker.py index e587cfa..d01eff6 100755 --- a/rule_checker.py +++ b/rule_checker.py @@ -97,9 +97,9 @@ def ruleCheckInc(file): files = 0 else: if re.search(r'^\s*[^#\s]+', line) and \ - not re.search(r'^\s*%include', line): + not re.search(r'^\s*(%include)|(%endif)|(%ifarch)', line): error += 1 - print("ERROR: RULE 5.3 a block must not have a file included") + print("ERROR: RULE 5.3 a block must not have a file included (%files section must be empty)") report(file, lc, line) continue