[ostree] gnomeos: Commit to OSTree repo inside bitbake
- From: Colin Walters <walters src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ostree] gnomeos: Commit to OSTree repo inside bitbake
- Date: Fri, 27 Jan 2012 12:34:29 +0000 (UTC)
commit c41469c22c2126e424692c60e3853ce436a3400b
Author: Colin Walters <walters verbum org>
Date: Fri Jan 27 07:33:10 2012 -0500
gnomeos: Commit to OSTree repo inside bitbake
gnomeos/yocto/classes/gnomeos-contents.bbclass | 27 ++++++++++++++++++++++++
1 files changed, 27 insertions(+), 0 deletions(-)
---
diff --git a/gnomeos/yocto/classes/gnomeos-contents.bbclass b/gnomeos/yocto/classes/gnomeos-contents.bbclass
index 0ca768c..096bed0 100644
--- a/gnomeos/yocto/classes/gnomeos-contents.bbclass
+++ b/gnomeos/yocto/classes/gnomeos-contents.bbclass
@@ -149,6 +149,33 @@ EOF
rm -f ${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.tar.gz
ln -s ${IMAGE_NAME}.rootfs.tar.gz ${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.tar.gz
echo "Created ${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.tar.gz"
+
+ set -x
+
+ if echo ${IMAGE_LINK_NAME} | grep -q -e -runtime; then
+ ostree_target=runtime
+ else
+ ostree_target=devel
+ fi
+ if test x${MACHINE_ARCH} = xqemux86; then
+ ostree_machine=i686
+ else
+ if test x${MACHINE_ARCH} = xqemux86_64; then
+ ostree_machine=x86_64
+ else
+ echo "error: unknown machine from ${MACHINE_ARCH}"; exit 1
+ fi
+ fi
+ buildroot=gnomeos-3.4-${ostree_machine}-${ostree_target}
+ base=bases/yocto/${buildroot}
+ repo=${DEPLOY_DIR_IMAGE}/repo
+ if ! test -d ${repo}; then
+ mkdir ${repo}
+ ostree --repo=${repo} init --archive
+ fi
+ ostree --repo=${repo} commit -s "${IMAGE_LINK_NAME}" --skip-if-unchanged "Build" -b ${base} --tree=tar=${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.tar.gz
+ ostree --repo=${repo} diff "${base}" || true
+ ostree --repo=${repo} compose -s "Initial compose" -b ${buildroot} ${base}:/
}
log_check() {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]