From: Alexander Smirnov <asmirnov@ilbers.de>
To: isar-users@googlegroups.com
Cc: Alexander Smirnov <asmirnov@ilbers.de>
Subject: [PATCH v2 2/5] isar: Change build folders tree
Date: Fri, 8 Sep 2017 18:56:03 +0300 [thread overview]
Message-ID: <20170908155606.7654-3-asmirnov@ilbers.de> (raw)
In-Reply-To: <20170908155606.7654-1-asmirnov@ilbers.de>
Differentiate folders tree, that are generated during build on
the highest possible level. So the overal tree now looks like the
following:
tmp/work/${DISTRO}-${DISTRO_ARCH}/${PF}
This approach eliminates lots of subfolders to diffirentiate
buildchroot and image for multiconfig builds. Now each configuration
has private tree.
Signed-off-by: Alexander Smirnov <asmirnov@ilbers.de>
---
meta-isar/recipes-core/images/isar-image-base.bb | 8 ++++----
meta/conf/isar-bitbake.conf | 5 ++++-
meta/recipes-devtools/buildchroot/buildchroot.bb | 8 ++++----
3 files changed, 12 insertions(+), 9 deletions(-)
diff --git a/meta-isar/recipes-core/images/isar-image-base.bb b/meta-isar/recipes-core/images/isar-image-base.bb
index 94cbc9e..cde506e 100644
--- a/meta-isar/recipes-core/images/isar-image-base.bb
+++ b/meta-isar/recipes-core/images/isar-image-base.bb
@@ -17,7 +17,7 @@ DEPENDS += "${IMAGE_INSTALL}"
IMAGE_PREINSTALL += "apt \
dbus"
-WORKDIR = "${TMPDIR}/work/${PN}/${MACHINE}/${DISTRO}"
+WORKDIR_NAME = "${PN}"
do_rootfs[stamp-extra-info] = "${MACHINE}-${DISTRO}"
@@ -36,9 +36,9 @@ do_rootfs() {
sed -i 's|##DISTRO_APT_SOURCE##|${DISTRO_APT_SOURCE}|' ${WORKDIR}/multistrap.conf
sed -i 's|##DISTRO_SUITE##|${DISTRO_SUITE}|' ${WORKDIR}/multistrap.conf
sed -i 's|##DISTRO_COMPONENTS##|${DISTRO_COMPONENTS}|' ${WORKDIR}/multistrap.conf
- sed -i 's|##CONFIG_SCRIPT##|./tmp/work/${PN}/${MACHINE}/${DISTRO}/configscript.sh|' ${WORKDIR}/multistrap.conf
- sed -i 's|##SETUP_SCRIPT##|./tmp/work/${PN}/${MACHINE}/${DISTRO}/setup.sh|' ${WORKDIR}/multistrap.conf
- sed -i 's|##DIR_HOOKS##|./tmp/work/${PN}/${MACHINE}/${DISTRO}/hooks_multistrap|' ${WORKDIR}/multistrap.conf
+ sed -i 's|##CONFIG_SCRIPT##|./${WORKDIR_RELATIVE}/configscript.sh|' ${WORKDIR}/multistrap.conf
+ sed -i 's|##SETUP_SCRIPT##|./${WORKDIR_RELATIVE}/setup.sh|' ${WORKDIR}/multistrap.conf
+ sed -i 's|##DIR_HOOKS##|./${WORKDIR_RELATIVE}/hooks_multistrap|' ${WORKDIR}/multistrap.conf
# Multistrap config use relative paths, so ensure that we are in the right folder
cd ${TOPDIR}
diff --git a/meta/conf/isar-bitbake.conf b/meta/conf/isar-bitbake.conf
index f85f5cc..9f3ab27 100644
--- a/meta/conf/isar-bitbake.conf
+++ b/meta/conf/isar-bitbake.conf
@@ -18,9 +18,12 @@
# ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
# OTHER DEALINGS IN THE SOFTWARE.
+WORKDIR_NAME ?= "${PF}"
+WORKDIR_RELATIVE = "tmp/work/${DISTRO}-${DISTRO_ARCH}/${WORKDIR_NAME}"
+WORKDIR = "${TOPDIR}/${WORKDIR_RELATIVE}"
DEPLOY_DIR_DEB = "${TMPDIR}/deploy/deb/${MACHINE}"
SSTATE_DIR ?= "${TMPDIR}/sstate-cache"
-BUILDCHROOT_DIR = "${TOPDIR}/tmp/work/buildchroot/${DISTRO}-${DISTRO_ARCH}/rootfs"
+BUILDCHROOT_DIR = "${TMPDIR}/work/${DISTRO}-${DISTRO_ARCH}/buildchroot/rootfs"
# Setup our default hash policy
BB_SIGNATURE_HANDLER ?= "noop"
diff --git a/meta/recipes-devtools/buildchroot/buildchroot.bb b/meta/recipes-devtools/buildchroot/buildchroot.bb
index ccba683..3587aa1 100644
--- a/meta/recipes-devtools/buildchroot/buildchroot.bb
+++ b/meta/recipes-devtools/buildchroot/buildchroot.bb
@@ -21,7 +21,7 @@ BUILDCHROOT_PREINSTALL ?= "gcc \
apt \
automake"
-WORKDIR = "${TMPDIR}/work/${PF}/${DISTRO}"
+WORKDIR_NAME = "buildchroot"
do_build[stamp-extra-info] = "${DISTRO}-${DISTRO_ARCH}"
@@ -40,9 +40,9 @@ do_build() {
sed -i 's|##DISTRO_APT_SOURCE##|${DISTRO_APT_SOURCE}|' ${WORKDIR}/multistrap.conf
sed -i 's|##DISTRO_SUITE##|${DISTRO_SUITE}|' ${WORKDIR}/multistrap.conf
sed -i 's|##DISTRO_COMPONENTS##|${DISTRO_COMPONENTS}|' ${WORKDIR}/multistrap.conf
- sed -i 's|##CONFIG_SCRIPT##|./tmp/work/${PF}/${DISTRO}/configscript.sh|' ${WORKDIR}/multistrap.conf
- sed -i 's|##SETUP_SCRIPT##|./tmp/work/${PF}/${DISTRO}/setup.sh|' ${WORKDIR}/multistrap.conf
- sed -i 's|##DIR_HOOKS##|./tmp/work/${PF}/${DISTRO}/hooks_multistrap|' ${WORKDIR}/multistrap.conf
+ sed -i 's|##CONFIG_SCRIPT##|./${WORKDIR_RELATIVE}/configscript.sh|' ${WORKDIR}/multistrap.conf
+ sed -i 's|##SETUP_SCRIPT##|./${WORKDIR_RELATIVE}/setup.sh|' ${WORKDIR}/multistrap.conf
+ sed -i 's|##DIR_HOOKS##|./${WORKDIR_RELATIVE}/hooks_multistrap|' ${WORKDIR}/multistrap.conf
# Multistrap config use relative paths, so ensure that we are in the right folder
cd ${TOPDIR}
--
2.1.4
next prev parent reply other threads:[~2017-09-08 15:56 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-08 15:56 [PATCH v2 0/5] Unify work space for packages Alexander Smirnov
2017-09-08 15:56 ` [PATCH v2 1/5] image: Unify path to image rootfs Alexander Smirnov
2017-09-08 16:00 ` Henning Schild
2017-09-08 15:56 ` Alexander Smirnov [this message]
2017-09-08 16:04 ` [PATCH v2 2/5] isar: Change build folders tree Henning Schild
2017-09-08 15:56 ` [PATCH v2 3/5] stamps: Name stamps canonicaly and unified Alexander Smirnov
2017-09-08 15:56 ` [PATCH v2 4/5] image: Name image " Alexander Smirnov
2017-09-08 15:56 ` [PATCH v2 5/5] class/dpkg: Unify workplace for packages Alexander Smirnov
2017-09-11 16:47 ` Henning Schild
2017-09-11 18:10 ` Alexander Smirnov
2017-09-08 16:06 ` [PATCH v2 0/5] Unify work space " Henning Schild
2017-09-08 16:10 ` Alexander Smirnov
2017-09-08 16:12 ` Alexander Smirnov
2017-09-08 16:15 ` Henning Schild
2017-09-11 7:36 ` Alexander Smirnov
2017-09-11 8:00 ` Henning Schild
2017-09-11 8:19 ` Alexander Smirnov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170908155606.7654-3-asmirnov@ilbers.de \
--to=asmirnov@ilbers.de \
--cc=isar-users@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox