From 482e70f47fed52f27c83cc41e6bdeeb8ad36c779 Mon Sep 17 00:00:00 2001 From: Chris Larson Date: Wed, 26 Aug 2009 03:58:03 -0700 Subject: package_ipk.bbclass: don't choke on empty SRC_URI. Signed-off-by: Chris Larson --- classes/package_ipk.bbclass | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'classes/package_ipk.bbclass') diff --git a/classes/package_ipk.bbclass b/classes/package_ipk.bbclass index e3a7522619..e5561082fd 100644 --- a/classes/package_ipk.bbclass +++ b/classes/package_ipk.bbclass @@ -266,10 +266,9 @@ python do_package_ipk () { ctrlfile.write("Replaces: %s\n" % ", ".join(rreplaces)) if rconflicts: ctrlfile.write("Conflicts: %s\n" % ", ".join(rconflicts)) - src_uri = bb.data.getVar("SRC_URI", localdata, 1) - if src_uri: - src_uri = re.sub("\s+", " ", src_uri) - ctrlfile.write("Source: %s\n" % " ".join(src_uri.split())) + src_uri = bb.data.getVar("SRC_URI", localdata, 1) or d.getVar("FILE", True) + src_uri = re.sub("\s+", " ", src_uri) + ctrlfile.write("Source: %s\n" % " ".join(src_uri.split())) ctrlfile.close() for script in ["preinst", "postinst", "prerm", "postrm"]: -- cgit v1.2.3