summaryrefslogtreecommitdiffstats
path: root/meta/classes/base.bbclass
diff options
context:
space:
mode:
authorRichard Purdie <richard@openedhand.com>2007-08-01 11:24:50 +0000
committerRichard Purdie <richard@openedhand.com>2007-08-01 11:24:50 +0000
commit09e3f98f7e64fe07159b6326bfcf586e29c59b46 (patch)
treea6e5ee12846fac87e26023562b9be50ecc23ddce /meta/classes/base.bbclass
parent841d5dc1e0a2fff4bb58d73c877bb31736609b16 (diff)
downloadpoky-09e3f98f7e64fe07159b6326bfcf586e29c59b46.tar.gz
base.bbclass: Minor performance tweak, add base_get_srcrev()
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2249 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/classes/base.bbclass')
-rw-r--r--meta/classes/base.bbclass11
1 files changed, 10 insertions, 1 deletions
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
index 4a1b09b1a4..e25913c87f 100644
--- a/meta/classes/base.bbclass
+++ b/meta/classes/base.bbclass
@@ -723,8 +723,11 @@ def base_after_parse(d):
723 if (old_arch == mach_arch): 723 if (old_arch == mach_arch):
724 # Nothing to do 724 # Nothing to do
725 return 725 return
726 if (bb.data.getVar('SRC_URI_OVERRIDES_PACKAGE_ARCH', d, 1) == '0'): 726 override = bb.data.getVar('SRC_URI_OVERRIDES_PACKAGE_ARCH', d, 1)
727
728 if not override or override == '0':
727 return 729 return
730
728 paths = [] 731 paths = []
729 for p in [ "${FILE_DIRNAME}/${PF}", "${FILE_DIRNAME}/${P}", "${FILE_DIRNAME}/${PN}", "${FILE_DIRNAME}/files", "${FILE_DIRNAME}" ]: 732 for p in [ "${FILE_DIRNAME}/${PF}", "${FILE_DIRNAME}/${P}", "${FILE_DIRNAME}/${PN}", "${FILE_DIRNAME}/files", "${FILE_DIRNAME}" ]:
730 paths.append(bb.data.expand(os.path.join(p, mach_arch), d)) 733 paths.append(bb.data.expand(os.path.join(p, mach_arch), d))
@@ -742,6 +745,12 @@ python () {
742 base_after_parse(d) 745 base_after_parse(d)
743} 746}
744 747
748def base_get_srcrev(d):
749 import bb
750
751 if bb.fetch.get_srcrev:
752 return bb.fetch.get_srcrev(d)
753 return "NOT IMPLEMENTED"
745 754
746# Patch handling 755# Patch handling
747inherit patch 756inherit patch