All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] core-image-minimal-initramfs: add libgcc into the initramfs image
@ 2019-03-07  6:51 Zhixiong Chi
  2019-03-07  9:05 ` Burton, Ross
  0 siblings, 1 reply; 7+ messages in thread
From: Zhixiong Chi @ 2019-03-07  6:51 UTC (permalink / raw)
  To: openembedded-core

Add the libgcc package into the initramfs image to avoid multithread
function error in the userspace(eg: pthread_cancel).

Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
---
 meta/recipes-core/images/core-image-minimal-initramfs.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-core/images/core-image-minimal-initramfs.bb b/meta/recipes-core/images/core-image-minimal-initramfs.bb
index 7df8ab1ebd..3cf2c7b01f 100644
--- a/meta/recipes-core/images/core-image-minimal-initramfs.bb
+++ b/meta/recipes-core/images/core-image-minimal-initramfs.bb
@@ -11,7 +11,7 @@ INITRAMFS_SCRIPTS ?= "\
                       initramfs-module-install-efi \
                      "
 
-PACKAGE_INSTALL = "${INITRAMFS_SCRIPTS} ${VIRTUAL-RUNTIME_base-utils} udev base-passwd ${ROOTFS_BOOTSTRAP_INSTALL}"
+PACKAGE_INSTALL = "${INITRAMFS_SCRIPTS} ${VIRTUAL-RUNTIME_base-utils} udev base-passwd libgcc ${ROOTFS_BOOTSTRAP_INSTALL}"
 
 # Do not pollute the initrd image with rootfs features
 IMAGE_FEATURES = ""
-- 
2.17.1



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] core-image-minimal-initramfs: add libgcc into the initramfs image
  2019-03-07  6:51 [PATCH] core-image-minimal-initramfs: add libgcc into the initramfs image Zhixiong Chi
@ 2019-03-07  9:05 ` Burton, Ross
  2019-03-07 10:00   ` Zhixiong Chi
  0 siblings, 1 reply; 7+ messages in thread
From: Burton, Ross @ 2019-03-07  9:05 UTC (permalink / raw)
  To: Zhixiong Chi; +Cc: OE-core

Wouldn't it be better to add that dependency to the packages which need it?

Ross

On Thu, 7 Mar 2019 at 06:53, Zhixiong Chi <zhixiong.chi@windriver.com> wrote:
>
> Add the libgcc package into the initramfs image to avoid multithread
> function error in the userspace(eg: pthread_cancel).
>
> Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
> ---
>  meta/recipes-core/images/core-image-minimal-initramfs.bb | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/meta/recipes-core/images/core-image-minimal-initramfs.bb b/meta/recipes-core/images/core-image-minimal-initramfs.bb
> index 7df8ab1ebd..3cf2c7b01f 100644
> --- a/meta/recipes-core/images/core-image-minimal-initramfs.bb
> +++ b/meta/recipes-core/images/core-image-minimal-initramfs.bb
> @@ -11,7 +11,7 @@ INITRAMFS_SCRIPTS ?= "\
>                        initramfs-module-install-efi \
>                       "
>
> -PACKAGE_INSTALL = "${INITRAMFS_SCRIPTS} ${VIRTUAL-RUNTIME_base-utils} udev base-passwd ${ROOTFS_BOOTSTRAP_INSTALL}"
> +PACKAGE_INSTALL = "${INITRAMFS_SCRIPTS} ${VIRTUAL-RUNTIME_base-utils} udev base-passwd libgcc ${ROOTFS_BOOTSTRAP_INSTALL}"
>
>  # Do not pollute the initrd image with rootfs features
>  IMAGE_FEATURES = ""
> --
> 2.17.1
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] core-image-minimal-initramfs: add libgcc into the initramfs image
  2019-03-07  9:05 ` Burton, Ross
@ 2019-03-07 10:00   ` Zhixiong Chi
  2019-03-07 12:33     ` Richard Purdie
  0 siblings, 1 reply; 7+ messages in thread
From: Zhixiong Chi @ 2019-03-07 10:00 UTC (permalink / raw)
  To: Burton, Ross; +Cc: OE-core

It's not for dependency of the package in the initramfs image,

just for the multithread application while the customer use initramfs image.

Since we use PACKAGE_INSTALL to override the rootfs in the initramfs bb 
file,

so we couldn't use the IMAGE_INSTALL_append to add the package in the 
local.conf.

Did you think if it should be added into the image? :-)

I know the initramfs is just to bootup the system. If the customer want 
to support the

multithread app, they can use the other types of the image.

Thanks.


On 2019年03月07日 17:05, Burton, Ross wrote:
> Wouldn't it be better to add that dependency to the packages which need it?
>
> Ross
>
> On Thu, 7 Mar 2019 at 06:53, Zhixiong Chi <zhixiong.chi@windriver.com> wrote:
>> Add the libgcc package into the initramfs image to avoid multithread
>> function error in the userspace(eg: pthread_cancel).
>>
>> Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
>> ---
>>   meta/recipes-core/images/core-image-minimal-initramfs.bb | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/meta/recipes-core/images/core-image-minimal-initramfs.bb b/meta/recipes-core/images/core-image-minimal-initramfs.bb
>> index 7df8ab1ebd..3cf2c7b01f 100644
>> --- a/meta/recipes-core/images/core-image-minimal-initramfs.bb
>> +++ b/meta/recipes-core/images/core-image-minimal-initramfs.bb
>> @@ -11,7 +11,7 @@ INITRAMFS_SCRIPTS ?= "\
>>                         initramfs-module-install-efi \
>>                        "
>>
>> -PACKAGE_INSTALL = "${INITRAMFS_SCRIPTS} ${VIRTUAL-RUNTIME_base-utils} udev base-passwd ${ROOTFS_BOOTSTRAP_INSTALL}"
>> +PACKAGE_INSTALL = "${INITRAMFS_SCRIPTS} ${VIRTUAL-RUNTIME_base-utils} udev base-passwd libgcc ${ROOTFS_BOOTSTRAP_INSTALL}"
>>
>>   # Do not pollute the initrd image with rootfs features
>>   IMAGE_FEATURES = ""
>> --
>> 2.17.1
>>
>> --
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.openembedded.org/mailman/listinfo/openembedded-core

-- 
---------------------
Thanks,
Zhixiong Chi
Tel: +86-10-8477-7036



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] core-image-minimal-initramfs: add libgcc into the initramfs image
  2019-03-07 10:00   ` Zhixiong Chi
@ 2019-03-07 12:33     ` Richard Purdie
  2019-03-07 12:39       ` Burton, Ross
  0 siblings, 1 reply; 7+ messages in thread
From: Richard Purdie @ 2019-03-07 12:33 UTC (permalink / raw)
  To: Zhixiong Chi, Burton, Ross; +Cc: OE-core

On Thu, 2019-03-07 at 18:00 +0800, Zhixiong Chi wrote:
> It's not for dependency of the package in the initramfs image,
> 
> just for the multithread application while the customer use initramfs
> image.
> 
> Since we use PACKAGE_INSTALL to override the rootfs in the initramfs
> bb 
> file,
> 
> so we couldn't use the IMAGE_INSTALL_append to add the package in
> the 
> local.conf.
> 
> Did you think if it should be added into the image? :-)
> 
> I know the initramfs is just to bootup the system. If the customer
> want to support the multithread app, they can use the other types of
> the image.

The customer needs to depend on libgcc in their app, or their
initramfs, we're not adding random dependencies to the initramfs "just
in case".

Cheers,

Richard






^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] core-image-minimal-initramfs: add libgcc into the initramfs image
  2019-03-07 12:33     ` Richard Purdie
@ 2019-03-07 12:39       ` Burton, Ross
  2019-03-07 14:45         ` Khem Raj
  0 siblings, 1 reply; 7+ messages in thread
From: Burton, Ross @ 2019-03-07 12:39 UTC (permalink / raw)
  To: Richard Purdie; +Cc: OE-core

On Thu, 7 Mar 2019 at 12:34, Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
> The customer needs to depend on libgcc in their app, or their
> initramfs, we're not adding random dependencies to the initramfs "just
> in case".

Part of the goal of my ELF parser rewrite was to make it easy to add
libgcc dependencies on binaries that use pthread_cancel automatically.

Ross


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] core-image-minimal-initramfs: add libgcc into the initramfs image
  2019-03-07 12:39       ` Burton, Ross
@ 2019-03-07 14:45         ` Khem Raj
  2019-03-07 14:47           ` Burton, Ross
  0 siblings, 1 reply; 7+ messages in thread
From: Khem Raj @ 2019-03-07 14:45 UTC (permalink / raw)
  To: Burton, Ross; +Cc: OE-core

On Thu, Mar 7, 2019 at 4:39 AM Burton, Ross <ross.burton@intel.com> wrote:
>
> On Thu, 7 Mar 2019 at 12:34, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > The customer needs to depend on libgcc in their app, or their
> > initramfs, we're not adding random dependencies to the initramfs "just
> > in case".
>
> Part of the goal of my ELF parser rewrite was to make it easy to add
> libgcc dependencies on binaries that use pthread_cancel automatically.
>

your suggestion about letting needing package rdep on it right, but
adding a hardcoded dependency on libgcc is not. We have to consider
a case where where there are alternatives to libgcc which can provide
same functionality and is preferred.

> Ross
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] core-image-minimal-initramfs: add libgcc into the initramfs image
  2019-03-07 14:45         ` Khem Raj
@ 2019-03-07 14:47           ` Burton, Ross
  0 siblings, 0 replies; 7+ messages in thread
From: Burton, Ross @ 2019-03-07 14:47 UTC (permalink / raw)
  To: Khem Raj; +Cc: OE-core

On Thu, 7 Mar 2019 at 14:46, Khem Raj <raj.khem@gmail.com> wrote:
> your suggestion about letting needing package rdep on it right, but
> adding a hardcoded dependency on libgcc is not. We have to consider
> a case where where there are alternatives to libgcc which can provide
> same functionality and is preferred.

Absolutely.

Ross


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-03-07 14:47 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-07  6:51 [PATCH] core-image-minimal-initramfs: add libgcc into the initramfs image Zhixiong Chi
2019-03-07  9:05 ` Burton, Ross
2019-03-07 10:00   ` Zhixiong Chi
2019-03-07 12:33     ` Richard Purdie
2019-03-07 12:39       ` Burton, Ross
2019-03-07 14:45         ` Khem Raj
2019-03-07 14:47           ` Burton, Ross

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.