diff options
author | Richard Purdie <rpurdie@linux.intel.com> | 2010-11-02 13:18:07 +0000 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2010-11-02 13:18:07 +0000 |
commit | ecf2eb1efa145d5c8f350697ec605ea58beb9ba7 (patch) | |
tree | adb5cd8d1e572cbf4db411f11e0412fe9c10748a /meta/classes | |
parent | 88f6f3fadf16d957bc24f5a3af4c4c67017353ad (diff) | |
download | openembedded-core-ecf2eb1efa145d5c8f350697ec605ea58beb9ba7.tar.gz openembedded-core-ecf2eb1efa145d5c8f350697ec605ea58beb9ba7.tar.bz2 openembedded-core-ecf2eb1efa145d5c8f350697ec605ea58beb9ba7.zip |
sstate: Provide a temporary mechanism to stop collisions between toolchain components in builds from scratch using sstate
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'meta/classes')
-rw-r--r-- | meta/classes/sstate.bbclass | 28 |
1 files changed, 27 insertions, 1 deletions
diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass index 3674a79060..5581af94b1 100644 --- a/meta/classes/sstate.bbclass +++ b/meta/classes/sstate.bbclass @@ -1,7 +1,9 @@ SSTATE_VERSION = "1" SSTATE_MANIFESTS = "${TMPDIR}/sstate-control" -SSTATE_MANFILEPREFIX = "${SSTATE_MANIFESTS}/manifest-${SSTATE_PKGARCH}-${PN}" +SSTATE_MANFILEBASE = "${SSTATE_MANIFESTS}/manifest-${SSTATE_PKGARCH}-" +SSTATE_MANFILEPREFIX = "${SSTATE_MANFILEBASE}${PN}" + SSTATE_PKGARCH = "${BASE_PACKAGE_ARCH}" SSTATE_PKGNAME = "sstate-${PN}-${MULTIMACH_ARCH}${TARGET_VENDOR}-${TARGET_OS}-${PV}-${PR}-${SSTATE_PKGARCH}-${SSTATE_VERSION}-${BB_TASKHASH}" @@ -84,6 +86,30 @@ def sstate_install(ss, d): if os.access(manifest, os.R_OK): bb.fatal("Package already staged (%s)?!" % manifest) + def checkmanifest(pn, task): + return os.access(bb.data.expand("${SSTATE_MANFILEBASE}%s.%s" % (pn, task), d), os.R_OK) + + skipinst = False + pn = d.getVar("PN", True) + if pn == "gcc-cross-initial": + if checkmanifest("gcc-cross", "populate-sysroot"): + skipinst = True + if checkmanifest("gcc-cross-intermediate", "populate-sysroot"): + skipinst = True + elif pn == "gcc-cross-intermediate": + if checkmanifest("gcc-cross", "populate-sysroot"): + skipinst = True + elif pn == "glibc-initial": + if checkmanifest("glibc", "populate-sysroot"): + skipinst = True + elif pn == "eglibc-initial": + if checkmanifest("eglibc", "populate-sysroot"): + skipinst = True + + if skipinst: + bb.note("Not staging %s.%s as sysroot already contains better functionality" % (pn, ss['name'])) + return + locks = [] for lock in ss['lockfiles']: locks.append(bb.utils.lockfile(lock)) |