perl: allow empty lines and comments in perl-rdepends.txt

With this change the rdepends file can now have empty lines
and comment lines. The perl-rdepends.txt generation will be
fixed with further commits to leverage this change.

(From OE-Core rev: 2256afc652d69e720a31f7c5858d5ab32b0065f2)

Signed-off-by: Awais Belal <awais_belal@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Awais Belal
2021-03-30 12:29:21 +05:00
committed by Richard Purdie
parent c4f54b4638
commit 6a0bac1fa9

View File

@@ -320,6 +320,9 @@ python split_perl_packages () {
# Read the pre-generated dependency file, and use it to set module dependecies
for line in open(d.expand("${WORKDIR}") + '/perl-rdepends.txt').readlines():
splitline = line.split()
# Filter empty lines and comments
if len(splitline) == 0 or splitline[0].startswith("#"):
continue
if bb.data.inherits_class('native', d):
module = splitline[0] + '-native'
depends = "perl-native"