All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] bitbake.conf: add whoami to HOSTTOOLS
@ 2017-03-29 20:45 Andrea Adami
  2017-03-29 21:06 ` Mark Hatle
  2017-03-29 21:09 ` Andreas Oberritter
  0 siblings, 2 replies; 7+ messages in thread
From: Andrea Adami @ 2017-03-29 20:45 UTC (permalink / raw)
  To: openembedded-core

Spotted in log do_compile of linux:

 /tmp/build/tmp-glibc/work-shared/c7x0/kernel-source/scripts/mkcompile_h:
 line 46: whoami: command not found

Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
---
 meta/conf/bitbake.conf | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index 96a9ed9..4f67413 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -462,7 +462,7 @@ HOSTTOOLS += " \
     mktemp mv nm objcopy objdump od patch perl pod2man printf pwd python \
     python2.7 python3 ranlib readelf readlink rm rmdir rpcgen sed sh sleep \
     sort split stat strings strip tail tar tee test touch tr true uname uniq \
-    wc wget which xargs \
+    wc wget which whoami xargs \
 "
 
 # Tools needed to run testimage runtime image testing
-- 
2.7.4



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

* Re: [PATCH] bitbake.conf: add whoami to HOSTTOOLS
  2017-03-29 20:45 [PATCH] bitbake.conf: add whoami to HOSTTOOLS Andrea Adami
@ 2017-03-29 21:06 ` Mark Hatle
  2017-03-29 21:09 ` Andreas Oberritter
  1 sibling, 0 replies; 7+ messages in thread
From: Mark Hatle @ 2017-03-29 21:06 UTC (permalink / raw)
  To: Andrea Adami, openembedded-core

On 3/29/17 3:45 PM, Andrea Adami wrote:
> Spotted in log do_compile of linux:
> 
>  /tmp/build/tmp-glibc/work-shared/c7x0/kernel-source/scripts/mkcompile_h:
>  line 46: whoami: command not found

We should not be embedding 'whoami' type information into compiled executables.

I'd almost suggest this is a bug in that specific program.  I'd prefer we remove
references to uname, whoami, etc.  (Things that are going to embed user specific
info.)

--Mark

> Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
> ---
>  meta/conf/bitbake.conf | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
> index 96a9ed9..4f67413 100644
> --- a/meta/conf/bitbake.conf
> +++ b/meta/conf/bitbake.conf
> @@ -462,7 +462,7 @@ HOSTTOOLS += " \
>      mktemp mv nm objcopy objdump od patch perl pod2man printf pwd python \
>      python2.7 python3 ranlib readelf readlink rm rmdir rpcgen sed sh sleep \
>      sort split stat strings strip tail tar tee test touch tr true uname uniq \
> -    wc wget which xargs \
> +    wc wget which whoami xargs \
>  "
>  
>  # Tools needed to run testimage runtime image testing
> 



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

* Re: [PATCH] bitbake.conf: add whoami to HOSTTOOLS
  2017-03-29 20:45 [PATCH] bitbake.conf: add whoami to HOSTTOOLS Andrea Adami
  2017-03-29 21:06 ` Mark Hatle
@ 2017-03-29 21:09 ` Andreas Oberritter
  2017-03-29 21:27   ` Mark Hatle
  2017-03-29 22:24   ` Richard Purdie
  1 sibling, 2 replies; 7+ messages in thread
From: Andreas Oberritter @ 2017-03-29 21:09 UTC (permalink / raw)
  To: Andrea Adami; +Cc: openembedded-core

On Wed, 29 Mar 2017 22:45:17 +0200
Andrea Adami <andrea.adami@gmail.com> wrote:

> Spotted in log do_compile of linux:
> 
>  /tmp/build/tmp-glibc/work-shared/c7x0/kernel-source/scripts/mkcompile_h:
>  line 46: whoami: command not found

As an alternative, we could set KBUILD_BUILD_USER (and possibly
KBUILD_BUILD_HOST) to a fixed or machine-based value in kernel.bbclass'
EXTRA_OEMAKE variable, which could also improve the reproducibility of
builds.

Regards,
Andreas


> 
> Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
> ---
>  meta/conf/bitbake.conf | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
> index 96a9ed9..4f67413 100644
> --- a/meta/conf/bitbake.conf
> +++ b/meta/conf/bitbake.conf
> @@ -462,7 +462,7 @@ HOSTTOOLS += " \
>      mktemp mv nm objcopy objdump od patch perl pod2man printf pwd python \
>      python2.7 python3 ranlib readelf readlink rm rmdir rpcgen sed sh sleep \
>      sort split stat strings strip tail tar tee test touch tr true uname uniq \
> -    wc wget which xargs \
> +    wc wget which whoami xargs \
>  "
>  
>  # Tools needed to run testimage runtime image testing



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

* Re: [PATCH] bitbake.conf: add whoami to HOSTTOOLS
  2017-03-29 21:09 ` Andreas Oberritter
@ 2017-03-29 21:27   ` Mark Hatle
  2017-03-29 22:24   ` Richard Purdie
  1 sibling, 0 replies; 7+ messages in thread
From: Mark Hatle @ 2017-03-29 21:27 UTC (permalink / raw)
  To: Andreas Oberritter, Andrea Adami; +Cc: openembedded-core

On 3/29/17 4:09 PM, Andreas Oberritter wrote:
> On Wed, 29 Mar 2017 22:45:17 +0200
> Andrea Adami <andrea.adami@gmail.com> wrote:
> 
>> Spotted in log do_compile of linux:
>>
>>  /tmp/build/tmp-glibc/work-shared/c7x0/kernel-source/scripts/mkcompile_h:
>>  line 46: whoami: command not found
> 
> As an alternative, we could set KBUILD_BUILD_USER (and possibly
> KBUILD_BUILD_HOST) to a fixed or machine-based value in kernel.bbclass'
> EXTRA_OEMAKE variable, which could also improve the reproducibility of
> builds.

Yes, this is a good alternative.

--Mark

> Regards,
> Andreas
> 
> 
>>
>> Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
>> ---
>>  meta/conf/bitbake.conf | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
>> index 96a9ed9..4f67413 100644
>> --- a/meta/conf/bitbake.conf
>> +++ b/meta/conf/bitbake.conf
>> @@ -462,7 +462,7 @@ HOSTTOOLS += " \
>>      mktemp mv nm objcopy objdump od patch perl pod2man printf pwd python \
>>      python2.7 python3 ranlib readelf readlink rm rmdir rpcgen sed sh sleep \
>>      sort split stat strings strip tail tar tee test touch tr true uname uniq \
>> -    wc wget which xargs \
>> +    wc wget which whoami xargs \
>>  "
>>  
>>  # Tools needed to run testimage runtime image testing
> 



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

* Re: [PATCH] bitbake.conf: add whoami to HOSTTOOLS
  2017-03-29 21:09 ` Andreas Oberritter
  2017-03-29 21:27   ` Mark Hatle
@ 2017-03-29 22:24   ` Richard Purdie
  2017-03-29 22:52     ` Andrea Adami
  1 sibling, 1 reply; 7+ messages in thread
From: Richard Purdie @ 2017-03-29 22:24 UTC (permalink / raw)
  To: Andreas Oberritter, Andrea Adami; +Cc: openembedded-core

On Wed, 2017-03-29 at 23:09 +0200, Andreas Oberritter wrote:
> On Wed, 29 Mar 2017 22:45:17 +0200
> Andrea Adami <andrea.adami@gmail.com> wrote:
> 
> > 
> > Spotted in log do_compile of linux:
> > 
> >  /tmp/build/tmp-glibc/work-shared/c7x0/kernel-
> > source/scripts/mkcompile_h:
> >  line 46: whoami: command not found
> As an alternative, we could set KBUILD_BUILD_USER (and possibly
> KBUILD_BUILD_HOST) to a fixed or machine-based value in
> kernel.bbclass'
> EXTRA_OEMAKE variable, which could also improve the reproducibility
> of
> builds.

Agreed, I already suggested we should figure out how to pass in a
deterministic value and said I would not accept a patch to add whoami
to HOSTTOOLS.

Cheers,

Richard


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

* Re: [PATCH] bitbake.conf: add whoami to HOSTTOOLS
  2017-03-29 22:24   ` Richard Purdie
@ 2017-03-29 22:52     ` Andrea Adami
  2017-03-30 10:02       ` Richard Purdie
  0 siblings, 1 reply; 7+ messages in thread
From: Andrea Adami @ 2017-03-29 22:52 UTC (permalink / raw)
  To: Richard Purdie; +Cc: openembedded-core

On Thu, Mar 30, 2017 at 12:24 AM, Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
> On Wed, 2017-03-29 at 23:09 +0200, Andreas Oberritter wrote:
>> On Wed, 29 Mar 2017 22:45:17 +0200
>> Andrea Adami <andrea.adami@gmail.com> wrote:
>>
>> >
>> > Spotted in log do_compile of linux:
>> >
>> >  /tmp/build/tmp-glibc/work-shared/c7x0/kernel-
>> > source/scripts/mkcompile_h:
>> >  line 46: whoami: command not found
>> As an alternative, we could set KBUILD_BUILD_USER (and possibly
>> KBUILD_BUILD_HOST) to a fixed or machine-based value in
>> kernel.bbclass'
>> EXTRA_OEMAKE variable, which could also improve the reproducibility
>> of
>> builds.
>
> Agreed, I already suggested we should figure out how to pass in a
> deterministic value and said I would not accept a patch to add whoami
> to HOSTTOOLS.
>
> Cheers,
>
> Richard

Hello,

well, I'm all for reproducible builds.
But there is the fact that this is the standard kernel behavior and we
never limited the user choices about how to build/configure a kernel.

Cheers
Andrea


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

* Re: [PATCH] bitbake.conf: add whoami to HOSTTOOLS
  2017-03-29 22:52     ` Andrea Adami
@ 2017-03-30 10:02       ` Richard Purdie
  0 siblings, 0 replies; 7+ messages in thread
From: Richard Purdie @ 2017-03-30 10:02 UTC (permalink / raw)
  To: Andrea Adami; +Cc: openembedded-core

On Thu, 2017-03-30 at 00:52 +0200, Andrea Adami wrote:
> On Thu, Mar 30, 2017 at 12:24 AM, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > 
> > On Wed, 2017-03-29 at 23:09 +0200, Andreas Oberritter wrote:
> > > 
> > > On Wed, 29 Mar 2017 22:45:17 +0200
> > > Andrea Adami <andrea.adami@gmail.com> wrote:
> > > 
> > > > 
> > > > 
> > > > Spotted in log do_compile of linux:
> > > > 
> > > >  /tmp/build/tmp-glibc/work-shared/c7x0/kernel-
> > > > source/scripts/mkcompile_h:
> > > >  line 46: whoami: command not found
> > > As an alternative, we could set KBUILD_BUILD_USER (and possibly
> > > KBUILD_BUILD_HOST) to a fixed or machine-based value in
> > > kernel.bbclass'
> > > EXTRA_OEMAKE variable, which could also improve the
> > > reproducibility
> > > of
> > > builds.
> > Agreed, I already suggested we should figure out how to pass in a
> > deterministic value and said I would not accept a patch to add
> > whoami
> > to HOSTTOOLS.
> > 
> > Cheers,
> > 
> > Richard
> Hello,
> 
> well, I'm all for reproducible builds.
> But there is the fact that this is the standard kernel behavior and
> we
> never limited the user choices about how to build/configure a kernel.

Just because this is the standard kernel behaviour, it doesn't mean its
"right" for us.

There are multiple issues here:

a) Builds are not deterministic
b) Builds leak "host" information about the user that built it

So we've identified an issue which I believe is something our general
userbase (who are asking for reproducibility) will want us to fix, even
if its not the upstream default kernel behaviour.

The fact there is a kconfig option for this and a way to override it
suggest even the upstream kernel people accept this is something people
will want to configure.

Cheers,

Richard


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

end of thread, other threads:[~2017-03-30 10:02 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-29 20:45 [PATCH] bitbake.conf: add whoami to HOSTTOOLS Andrea Adami
2017-03-29 21:06 ` Mark Hatle
2017-03-29 21:09 ` Andreas Oberritter
2017-03-29 21:27   ` Mark Hatle
2017-03-29 22:24   ` Richard Purdie
2017-03-29 22:52     ` Andrea Adami
2017-03-30 10:02       ` Richard Purdie

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.