All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Alexander Kanavin" <alex.kanavin@gmail.com>
To: Michael Ho <Michael.Ho@bmw.de>
Cc: OE-core <openembedded-core@lists.openembedded.org>
Subject: Re: [OE-core] [PATCH] rootfs_ipk: allow do_populate_sdk in parallel to do_rootfs
Date: Mon, 11 Jan 2021 19:44:31 +0100	[thread overview]
Message-ID: <CANNYZj9ysR=FRKbZ8jC9mkNHtVkA0AZfA5EXk68jGwSTV-pTcA@mail.gmail.com> (raw)
In-Reply-To: <48E89C79-DCF6-4AB8-B362-0846382C3208@bmw.de>

[-- Attachment #1: Type: text/plain, Size: 6725 bytes --]

Right, then don't bother with deb. The level of support for deb in Yocto is
significantly less than for rpm/ipk, and we do not require feature parity
for all three.

Thanks,
Alex

On Mon, 11 Jan 2021 at 17:25, <Michael.Ho@bmw.de> wrote:

> Hello Alex,
>
>
>
> Seems to not be so quick to change for the deb packages. First I had
> issues building the sdk on
> the master branch as it runs some postinst scripts that leak out of the
> yocto sandbox and into
> the host system [1]. Not sure if that’s a recent regression as I don’t
> normally use deb packages
> in Yocto.
>
>
>
> Then I found that apt will fight over a lock file written into the
> recipe-sysroots-native directory [2].
> I am not so familiar with apt-get to resolve that trivially. I’ll try to
> re-visit it another day.
>
>
>
> Kind regards,
>
> Michael
>
>
>
> [1]
>
> Setting up nativesdk-shadow (4.8.1-r0) ...
>
> mkdir: cannot create directory ‘/usr/lib/opkg’: Permission denied
>
> dpkg: error processing package nativesdk-shadow (--configure):
>
>  installed nativesdk-shadow package post-installation script subprocess
> returned error exit status 1
>
>
>
> [2]
>
> E: Could not get lock
> /nvme/poky/build-deb/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/recipe-sysroot-native/var/cache/apt/archives/lock
> - open (11: Resource temporarily unavailable)
>
>
>
> --
>
> *BMW Car IT GmbH*
> Michael Ho
> Spezialist Entwicklung – Build and Release Engineering
> Lise-Meitner-Straße 14
> 89081 Ulm
>
> Tel.: ­+49-731-37804-071
>
> Mobil: +49-152-54980-471
> Fax: +49-731-37804-001
> Mail: michael.ho@bmw-carit.de
> Web: http://www.bmw-carit.de
> -------------------------------------------------------------------------
> BMW Car IT GmbH
> Geschäftsführer: Kai-Uwe Balszuweit und Michael Böttrich
> Sitz und Registergericht: München HRB 134810
> -------------------------------------------------------------------------
>
>
>
>
>
> *From: *Alexander Kanavin <alex.kanavin@gmail.com>
> *Date: *Monday, 11. January 2021 at 15:45
> *To: *"Ho Michael, JC-3UL" <Michael.Ho@bmw.de>
> *Cc: *OE-core <openembedded-core@lists.openembedded.org>
> *Subject: *Re: [OE-core] [PATCH] rootfs_ipk: allow do_populate_sdk in
> parallel to do_rootfs
>
>
>
> If you can fix the deb packaging easily, then please do so, but it is not
> mandatory, and don't spend too much time if it turns out to be a time sink.
>
>
>
> Alex
>
>
>
> On Mon, 11 Jan 2021 at 15:01, <Michael.Ho@bmw.de> wrote:
>
> Hello Alexander,
>
>
>
> Did a quick test and it seems the rpm packaging classes don’t have this
> issue. The rootfs_deb bbclass however has the same lock files like with
> rootfs_ipk.
>
> Should I try to patch this too to keep them aligned?
>
>
>
> Kind regards,
>
> Michael
>
>
>
> --
>
> *BMW Car IT GmbH*
> Michael Ho
> Spezialist Entwicklung – Build and Release Engineering
> Lise-Meitner-Straße 14
> 89081 Ulm
>
> Tel.: ­+49-731-37804-071
>
> Mobil: +49-152-54980-471
> Fax: +49-731-37804-001
> Mail: michael.ho@bmw-carit.de
> Web: http://www.bmw-carit.de
> -------------------------------------------------------------------------
> BMW Car IT GmbH
> Geschäftsführer: Kai-Uwe Balszuweit und Michael Böttrich
> Sitz und Registergericht: München HRB 134810
> -------------------------------------------------------------------------
>
>
>
>
>
> *From: *Alexander Kanavin <alex.kanavin@gmail.com>
> *Date: *Monday, 11. January 2021 at 13:46
> *To: *"Ho Michael, JC-3UL" <Michael.Ho@bmw.de>
> *Cc: *OE-core <openembedded-core@lists.openembedded.org>
> *Subject: *Re: [OE-core] [PATCH] rootfs_ipk: allow do_populate_sdk in
> parallel to do_rootfs
>
>
>
> Does deb/rpm packaging already have this feature?
>
>
>
> Alex
>
>
>
> On Mon, 11 Jan 2021 at 13:45, Michael Ho <Michael.Ho@bmw.de> wrote:
>
> From: Michael Ho <Michael.Ho@bmw.de>
>
> Switch do_populate_sdk for the ipk package manager to use a separate target
> opkg config file and separate the lockfiles restricting do_rootfs and
> do_populate_sdk from running in parallel.
>
> This way if an image recipe includes a dependency to do_populate_sdk by
> default then it will run in parallel to do_rootfs saving time compared to
> the
> sequential execution.
>
> Signed-off-by: Michael Ho <Michael.Ho@bmw.de>
> ---
>  meta/classes/package_ipk.bbclass       | 1 +
>  meta/classes/rootfs_ipk.bbclass        | 4 ++--
>  meta/lib/oe/package_manager/ipk/sdk.py | 6 ++++++
>  3 files changed, 9 insertions(+), 2 deletions(-)
>
> diff --git a/meta/classes/package_ipk.bbclass
> b/meta/classes/package_ipk.bbclass
> index 79cb36c..d31dba0 100644
> --- a/meta/classes/package_ipk.bbclass
> +++ b/meta/classes/package_ipk.bbclass
> @@ -4,6 +4,7 @@ IMAGE_PKGTYPE ?= "ipk"
>
>  IPKGCONF_TARGET = "${WORKDIR}/opkg.conf"
>  IPKGCONF_SDK =  "${WORKDIR}/opkg-sdk.conf"
> +IPKGCONF_SDK_TARGET = "${WORKDIR}/opkg-sdk-target.conf"
>
>  PKGWRITEDIRIPK = "${WORKDIR}/deploy-ipks"
>
> diff --git a/meta/classes/rootfs_ipk.bbclass
> b/meta/classes/rootfs_ipk.bbclass
> index f1e0219..245c256 100644
> --- a/meta/classes/rootfs_ipk.bbclass
> +++ b/meta/classes/rootfs_ipk.bbclass
> @@ -14,8 +14,8 @@ do_rootfs[recrdeptask] += "do_package_write_ipk
> do_package_qa"
>  do_rootfs[vardeps] += "PACKAGE_FEED_URIS PACKAGE_FEED_BASE_PATHS
> PACKAGE_FEED_ARCHS"
>
>  do_rootfs[lockfiles] += "${WORKDIR}/ipk.lock"
> -do_populate_sdk[lockfiles] += "${WORKDIR}/ipk.lock"
> -do_populate_sdk_ext[lockfiles] += "${WORKDIR}/ipk.lock"
> +do_populate_sdk[lockfiles] += "${WORKDIR}/sdk-ipk.lock"
> +do_populate_sdk_ext[lockfiles] += "${WORKDIR}/sdk-ipk.lock"
>
>  OPKG_PREPROCESS_COMMANDS = ""
>
> diff --git a/meta/lib/oe/package_manager/ipk/sdk.py
> b/meta/lib/oe/package_manager/ipk/sdk.py
> index 37af034..e2ca415 100644
> --- a/meta/lib/oe/package_manager/ipk/sdk.py
> +++ b/meta/lib/oe/package_manager/ipk/sdk.py
> @@ -14,6 +14,12 @@ class PkgSdk(Sdk):
>      def __init__(self, d, manifest_dir=None):
>          super(PkgSdk, self).__init__(d, manifest_dir)
>
> +        # In sdk_list_installed_packages the call to opkg is hardcoded to
> +        # always use IPKGCONF_TARGET and there's no exposed API to change
> this
> +        # so simply override IPKGCONF_TARGET to use this separated config
> file.
> +        ipkgconf_sdk_target = d.getVar("IPKGCONF_SDK_TARGET")
> +        d.setVar("IPKGCONF_TARGET", ipkgconf_sdk_target)
> +
>          self.target_conf = self.d.getVar("IPKGCONF_TARGET")
>          self.host_conf = self.d.getVar("IPKGCONF_SDK")
>
> --
> 2.7.4
>
>
> 
>
>

[-- Attachment #2: Type: text/html, Size: 16584 bytes --]

  reply	other threads:[~2021-01-11 18:44 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-11 12:45 [PATCH] rootfs_ipk: allow do_populate_sdk in parallel to do_rootfs Michael Ho
2021-01-11 12:46 ` [OE-core] " Alexander Kanavin
2021-01-11 14:01   ` Michael Ho
2021-01-11 14:45     ` Alexander Kanavin
2021-01-11 16:25       ` Michael Ho
2021-01-11 18:44         ` Alexander Kanavin [this message]
2021-01-12  9:21 ` Richard Purdie
2021-01-12  9:57   ` Paul Barker
     [not found] ` <1659719EDE2CEAAC.30796@lists.openembedded.org>
2021-01-12 11:58   ` Richard Purdie
2021-01-12 17:02     ` Michael Ho

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='CANNYZj9ysR=FRKbZ8jC9mkNHtVkA0AZfA5EXk68jGwSTV-pTcA@mail.gmail.com' \
    --to=alex.kanavin@gmail.com \
    --cc=Michael.Ho@bmw.de \
    --cc=openembedded-core@lists.openembedded.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.