diff options
author | Ed Bartosh <ed.bartosh@linux.intel.com> | 2016-09-01 11:56:02 +0300 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-09-04 00:05:12 +0100 |
commit | 8361376b8ef0147276c9ee31349e904d86900593 (patch) | |
tree | 184a45601c00b54a279e3b676275d04569af8f3d /meta/classes | |
parent | 4bd3a90c8fb034b4d899d0560d75d81f56e27e0a (diff) | |
download | openembedded-core-contrib-8361376b8ef0147276c9ee31349e904d86900593.tar.gz |
populate_sdk_base: Put populate_sdk under sstate control
Adding populate_sdk task to SSTATE_TASKS should make sstate machinery
to generate manifest for deployed sdk artifacts and do final deployment
to SDK_DEPLOY.
Set stamp-extra-info flag for do_populate_sdk task. This flag is used
in the name of sstate manifest. Setting it to predetermined value for
populate_sdk task should help to get correct manifest filenames when
processing runQueueTask events.
The do_populate_sdk function is also executed by do_populate_sdk_ext
so in order to avoid conflicts with the sstate postfuncs, split
the main code into a separate function.
We also need to set SDKDEPLOYDIR as do_populate_sdk_ext expects
it in order not to break ESDK generation.
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r-- | meta/classes/populate_sdk_base.bbclass | 13 | ||||
-rw-r--r-- | meta/classes/populate_sdk_ext.bbclass | 3 |
2 files changed, 13 insertions, 3 deletions
diff --git a/meta/classes/populate_sdk_base.bbclass b/meta/classes/populate_sdk_base.bbclass index 5f526605536..6fe0b3704a1 100644 --- a/meta/classes/populate_sdk_base.bbclass +++ b/meta/classes/populate_sdk_base.bbclass @@ -26,7 +26,7 @@ SDK_DIR = "${WORKDIR}/sdk" SDK_OUTPUT = "${SDK_DIR}/image" SDK_DEPLOY = "${DEPLOY_DIR}/sdk" -SDKDEPLOYDIR = "${SDK_DEPLOY}" +SDKDEPLOYDIR = "${WORKDIR}/deploy-${PN}-populate-sdk" B_task-populate-sdk = "${SDK_DIR}" @@ -94,7 +94,7 @@ SDK_POSTPROCESS_COMMAND = " create_sdk_files; check_sdk_sysroots; tar_sdk; ${SDK # manipulation. SDK_OLDEST_KERNEL = "3.2.0" -fakeroot python do_populate_sdk() { +def populate_sdk_common(d): from oe.sdk import populate_sdk from oe.manifest import create_manifest, Manifest @@ -116,7 +116,16 @@ fakeroot python do_populate_sdk() { manifest_type=Manifest.MANIFEST_TYPE_SDK_TARGET) populate_sdk(d) + +fakeroot python do_populate_sdk() { + populate_sdk_common(d) } +SSTATETASKS += "do_populate_sdk" +SSTATE_SKIP_CREATION_task-populate-sdk = '1' +do_populate_sdk[cleandirs] = "${SDKDEPLOYDIR}" +do_populate_sdk[sstate-inputdirs] = "${SDKDEPLOYDIR}" +do_populate_sdk[sstate-outputdirs] = "${SDK_DEPLOY}" +do_populate_sdk[stamp-extra-info] = "${MACHINE}" fakeroot create_sdk_files() { cp ${COREBASE}/scripts/relocate_sdk.py ${SDK_OUTPUT}/${SDKPATH}/ diff --git a/meta/classes/populate_sdk_ext.bbclass b/meta/classes/populate_sdk_ext.bbclass index b52ad41d3dc..906ae749fc9 100644 --- a/meta/classes/populate_sdk_ext.bbclass +++ b/meta/classes/populate_sdk_ext.bbclass @@ -599,8 +599,9 @@ fakeroot python do_populate_sdk_ext() { buildtools_fn = get_current_buildtools(d) d.setVar('SDK_REQUIRED_UTILITIES', get_sdk_required_utilities(buildtools_fn, d)) d.setVar('SDK_BUILDTOOLS_INSTALLER', buildtools_fn) + d.setVar('SDKDEPLOYDIR', '${DEPLOY_DIR}/sdk') - bb.build.exec_func("do_populate_sdk", d) + populate_sdk_common(d) } def get_ext_sdk_depends(d): |