Openembedded Devel Discussions
 help / color / mirror / Atom feed
From: Robert Yang <liezhi.yang@windriver.com>
To: <openembedded-devel@lists.openembedded.org>
Subject: Re: [PATCH 5/8] cim-schema-exper: fix host-user-contaminated
Date: Sun, 22 Nov 2015 14:55:14 +0800	[thread overview]
Message-ID: <565166D2.3050904@windriver.com> (raw)
In-Reply-To: <20151120094215.GC2241@jama>



On 11/20/2015 05:42 PM, Martin Jansa wrote:
> On Fri, Nov 20, 2015 at 01:32:44AM -0800, Robert Yang wrote:
>> Issue: LIN8-1632
>>
>> Fixed:
>> cim-schema-exper-2.39.0: cim-schema-exper: /cim-schema-exper/usr/share/mof/cimv2.39.0/Network/CIM_IPAddressRange.mof is owned by uid 15220, which is the same as the user running bitbake. This may be due to host contamination [host-user-contaminated]
>> cim-schema-final-2.40.0: cim-schema-final: /cim-schema-final/usr/share/mof/cimv2.40.0/Network/CIM_IPAddressRange.mof is owned by uid 15220, which is the same as the user running bitbake. This may be due to host contamination [host-user-contaminated]
>> lib32-cim-schema-exper-2.39.0: lib32-cim-schema-exper: /lib32-cim-schema-exper/usr/share/mof/cimv2.39.0/Network/CIM_IPAddressRange.mof is owned by uid 15220, which is the same as the user running bitbake. This may be due to host contamination [host-user-contaminated]
>> lib32-cim-schema-final-2.40.0: lib32-cim-schema-final: /lib32-cim-schema-final/usr/share/mof/cimv2.40.0/Network/CIM_IPAddressRange.mof is owned by uid 15220, which is the same as the user running bitbake. This may be due to host contamination [host-user-contaminated]
>>
>> It uses cp -a to install the files, so fix the owner to root:root
>>
>> (LOCAL REV: NOT UPSTREAM) -- Sent to oe-devel on 20151120
>>
>> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
>> ---
>>   .../cim-schema/cim-schema-exper_2.39.0.bb          |    1 +
>>   .../cim-schema/cim-schema-final_2.40.0.bb          |    1 +
>>   2 files changed, 2 insertions(+)
>>
>> diff --git a/meta-networking/recipes-support/cim-schema/cim-schema-exper_2.39.0.bb b/meta-networking/recipes-support/cim-schema/cim-schema-exper_2.39.0.bb
>> index 62e50df..e4ed7b3 100644
>> --- a/meta-networking/recipes-support/cim-schema/cim-schema-exper_2.39.0.bb
>> +++ b/meta-networking/recipes-support/cim-schema/cim-schema-exper_2.39.0.bb
>> @@ -17,6 +17,7 @@ do_install() {
>>           install -m 644 ${WORKDIR}/LICENSE ${D}${datadir}/doc/cim-schema-${PV}
>>
>>           cp -a ${S}/* ${D}${datadir}/mof/cimv${PV}/	
>> +        chown -R root:root ${D}${datadir}/mof/cimv${PV}
>
> Why don't you fix it to use install instead of cp -a + chown?

Because there are a lot of files and directories:

$ find cim-schema-exper/image/usr/share/mof/cimv2.39.0/ -type f |wc -l
1816

$ find cim-schema-exper/image/usr/share/mof/cimv2.39.0/ -type d |wc -l
15

I think that's why it used cp -a before. And we did use chown to fix such
issues for several recipes in oe-core and meta-openembedded.

// Robert

>
>>           for i in `find ${D}${datadir}/mof/cimv${PV} -name "*.mof"`; do
>>                   sed -i -e 's/\r//g' $i
>>           done
>> diff --git a/meta-networking/recipes-support/cim-schema/cim-schema-final_2.40.0.bb b/meta-networking/recipes-support/cim-schema/cim-schema-final_2.40.0.bb
>> index 1694f31..7ab9c4d 100644
>> --- a/meta-networking/recipes-support/cim-schema/cim-schema-final_2.40.0.bb
>> +++ b/meta-networking/recipes-support/cim-schema/cim-schema-final_2.40.0.bb
>> @@ -22,6 +22,7 @@ do_install() {
>>           install -m 644 ${WORKDIR}/LICENSE ${D}${datadir}/doc/cim-schema-${PV}
>>
>>           cp -a ${S}/* ${D}${datadir}/mof/cimv${PV}/	
>> +        chown -R root:root ${D}${datadir}/mof/cimv${PV}/
>>           for i in `find ${D}${datadir}/mof/cimv${PV} -name "*.mof"`; do
>>                   sed -i -e 's/\r//g' $i
>>           done
>> --
>> 1.7.9.5
>>
>> --
>> _______________________________________________
>> Openembedded-devel mailing list
>> Openembedded-devel@lists.openembedded.org
>> http://lists.openembedded.org/mailman/listinfo/openembedded-devel
>
>
>


  reply	other threads:[~2015-11-22  6:55 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-20  9:32 [PATCH 0/8] meta-openembedded: fix QA issues Robert Yang
2015-11-20  9:32 ` [PATCH 1/8] netmap-modules: fix for --no-drivers Robert Yang
2015-11-20  9:41   ` Martin Jansa
2015-11-22  6:55     ` Robert Yang
2015-11-20  9:32 ` [PATCH 2/8] lldpad: fix installed-vs-shipped Robert Yang
2015-12-11 13:54   ` Martin Jansa
2015-11-20  9:32 ` [PATCH 3/8] nbd: use BPN in Files Robert Yang
2015-11-20  9:32 ` [PATCH 4/8] dracut: fix host-user-contaminated Robert Yang
2015-11-20  9:32 ` [PATCH 5/8] cim-schema-exper: " Robert Yang
2015-11-20  9:42   ` Martin Jansa
2015-11-22  6:55     ` Robert Yang [this message]
2015-11-20  9:32 ` [PATCH 6/8] ctdb: RDEPENDS on bash Robert Yang
2015-11-20  9:32 ` [PATCH 7/8] ctdb: add PACKAGECONFIG for libtdb Robert Yang
2015-11-20  9:32 ` [PATCH 8/8] netkit-ftp: fixed invalid symlink Robert Yang
2015-11-20  9:35 ` [PATCH 0/8] meta-openembedded: fix QA issues Robert Yang

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=565166D2.3050904@windriver.com \
    --to=liezhi.yang@windriver.com \
    --cc=openembedded-devel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox