Skip to contentSkip to conversation

recipes: Replace "cp -a" with "cp -R --no-dereference --preserve=mode, links"

PATCH In review Martin Jansa 4 participants 7 messages May 30, 2017 – Jun 4, 2017

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 recipes: Replace "cp -a" with "cp -R --no-dereference --preserve=mode, links"

* Using "cp -a" leaks UID of user running the builds, causing many QA warnings.
* See this thread for details:
http://lists.openembedded.org/pipermail/openembedded-core/2015-November/112904.html

---
 meta/recipes-core/coreutils/coreutils_8.27.bb       | 2 +-
 meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb | 4 ++--
 meta/recipes-extended/mdadm/mdadm_4.0.bb            | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)
meta/recipes-core/coreutils/coreutils_8.27.bb +1 -1
index 667e0af560..ea8740a2d1 100644
@@ -99,7 +99,7 @@ do_install_append() {
 	install -t ${D}/${mandir}/man1 ${S}/man/*.1
 	# prebuilt man pages don't do a separate man page for [ vs test.
 	# see comment above r.e. sed and update-alternatives
-	cp -a ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}
+	cp -R --no-dereference --preserve=mode,links -v ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}
 }
 
 inherit update-alternatives
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +2 -2
index 5216c7027c..7c8809a41e 100644
@@ -106,7 +106,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-	cp -a ${B}/tests ${D}${PTEST_PATH}/test
-	cp -a ${S}/tests/* ${D}${PTEST_PATH}/test
+	cp -R --no-dereference --preserve=mode,links -v ${B}/tests ${D}${PTEST_PATH}/test
+	cp -R --no-dereference --preserve=mode,links -v ${S}/tests/* ${D}${PTEST_PATH}/test
 	sed -e 's!../e2fsck/e2fsck!e2fsck!g' -i ${D}${PTEST_PATH}/test/*/expect*
 }
meta/recipes-extended/mdadm/mdadm_4.0.bb +1 -1
index 98a10a8b15..506b0bc315 100644
@@ -55,7 +55,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-	cp -a ${S}/tests ${D}${PTEST_PATH}/tests
+	cp -R --no-dereference --preserve=mode,links -v ${S}/tests ${D}${PTEST_PATH}/tests
 	cp ${S}/test ${D}${PTEST_PATH}
 	sed -e 's!sleep 0.*!sleep 1!g; s!/var/tmp!/!g' -i ${D}${PTEST_PATH}/test
 	ln -s ${base_sbindir}/mdadm ${D}${PTEST_PATH}/mdadm
Signature · 1 line
2.13.0
#1 lore raw
Quoted 4 lines · Martin Jansa

* Using "cp -a" leaks UID of user running the builds, causing many QA warnings.
* See this thread for details:
http://lists.openembedded.org/pipermail/openembedded-core/2015-November/112904.html

Using "cp -av --no-preserve=ownership" is a slightly cleaner solution.

Quoted 55 lines
---
 meta/recipes-core/coreutils/coreutils_8.27.bb       | 2 +-
 meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb | 4 ++--
 meta/recipes-extended/mdadm/mdadm_4.0.bb            | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)
meta/recipes-core/coreutils/coreutils_8.27.bb +1 -1
index 667e0af560..ea8740a2d1 100644
@@ -99,7 +99,7 @@ do_install_append() {
        install -t ${D}/${mandir}/man1 ${S}/man/*.1
        # prebuilt man pages don't do a separate man page for [ vs test.
        # see comment above r.e. sed and update-alternatives
-       cp -a ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}
+       cp -R --no-dereference --preserve=mode,links -v ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}
 }
 
 inherit update-alternatives
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +2 -2
index 5216c7027c..7c8809a41e 100644
@@ -106,7 +106,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${B}/tests ${D}${PTEST_PATH}/test
-       cp -a ${S}/tests/* ${D}${PTEST_PATH}/test
+       cp -R --no-dereference --preserve=mode,links -v ${B}/tests ${D}${PTEST_PATH}/test
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests/* ${D}${PTEST_PATH}/test
        sed -e 's!../e2fsck/e2fsck!e2fsck!g' -i ${D}${PTEST_PATH}/test/*/expect*
 }
meta/recipes-extended/mdadm/mdadm_4.0.bb +1 -2
index 98a10a8b15..506b0bc315 100644
@@ -55,7 +55,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${S}/tests ${D}${PTEST_PATH}/tests
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests ${D}${PTEST_PATH}/tests
        cp ${S}/test ${D}${PTEST_PATH}
        sed -e 's!sleep 0.*!sleep 1!g; s!/var/tmp!/!g' -i ${D}${PTEST_PATH}/test
        ln -s ${base_sbindir}/mdadm ${D}${PTEST_PATH}/mdadm
--

2.13.0

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#2 lore raw
Quoted 7 lines · Andre McCurdy
Quoted 4 lines · Martin Jansa

* Using "cp -a" leaks UID of user running the builds, causing many QA warnings.
* See this thread for details:
http://lists.openembedded.org/pipermail/openembedded-core/2015-November/112904.html

Using "cp -av --no-preserve=ownership" is a slightly cleaner solution.

I personally prefer Martin's version since '-a' is not supported everywhere. (Unless you using gnu cp, which 99% of the Linux world uses.. but non-Linux systems rarely do.)

--Mark

Quoted 55 lines
Quoted 55 lines
---
 meta/recipes-core/coreutils/coreutils_8.27.bb       | 2 +-
 meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb | 4 ++--
 meta/recipes-extended/mdadm/mdadm_4.0.bb            | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)
meta/recipes-core/coreutils/coreutils_8.27.bb +1 -1
index 667e0af560..ea8740a2d1 100644
@@ -99,7 +99,7 @@ do_install_append() {
        install -t ${D}/${mandir}/man1 ${S}/man/*.1
        # prebuilt man pages don't do a separate man page for [ vs test.
        # see comment above r.e. sed and update-alternatives
-       cp -a ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}
+       cp -R --no-dereference --preserve=mode,links -v ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}
 }
 
 inherit update-alternatives
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +2 -2
index 5216c7027c..7c8809a41e 100644
@@ -106,7 +106,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${B}/tests ${D}${PTEST_PATH}/test
-       cp -a ${S}/tests/* ${D}${PTEST_PATH}/test
+       cp -R --no-dereference --preserve=mode,links -v ${B}/tests ${D}${PTEST_PATH}/test
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests/* ${D}${PTEST_PATH}/test
        sed -e 's!../e2fsck/e2fsck!e2fsck!g' -i ${D}${PTEST_PATH}/test/*/expect*
 }
meta/recipes-extended/mdadm/mdadm_4.0.bb +1 -2
index 98a10a8b15..506b0bc315 100644
@@ -55,7 +55,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${S}/tests ${D}${PTEST_PATH}/tests
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests ${D}${PTEST_PATH}/tests
        cp ${S}/test ${D}${PTEST_PATH}
        sed -e 's!sleep 0.*!sleep 1!g; s!/var/tmp!/!g' -i ${D}${PTEST_PATH}/test
        ln -s ${base_sbindir}/mdadm ${D}${PTEST_PATH}/mdadm
--

2.13.0

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#3 lore raw
Quoted 7 lines · Mark Hatle
Quoted 6 lines · Andre McCurdy
Quoted 4 lines · Martin Jansa

* Using "cp -a" leaks UID of user running the builds, causing many QA warnings.
* See this thread for details:
http://lists.openembedded.org/pipermail/openembedded-core/2015-November/112904.html

Quoted 5 lines
Quoted 1 line

Using "cp -av --no-preserve=ownership" is a slightly cleaner solution.

I personally prefer Martin's version since '-a' is not supported everywhere. (Unless you using gnu cp, which 99% of the Linux world uses.. but non-Linux systems rarely do.)

Which versions of cp do you know of that support
"--preserve=mode,links" without supporting "-a" ?

A quick google of manpages suggests that FreeBSD supports "-a" but not "--preserve=XXX". OpenBSD doesn't seem to support either.

Which non-Linux host systems does OE support?

Quoted 58 lines

--Mark

Quoted 55 lines
Quoted 55 lines
---
 meta/recipes-core/coreutils/coreutils_8.27.bb       | 2 +-
 meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb | 4 ++--
 meta/recipes-extended/mdadm/mdadm_4.0.bb            | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)
meta/recipes-core/coreutils/coreutils_8.27.bb +1 -1
index 667e0af560..ea8740a2d1 100644
@@ -99,7 +99,7 @@ do_install_append() {
        install -t ${D}/${mandir}/man1 ${S}/man/*.1
        # prebuilt man pages don't do a separate man page for [ vs test.
        # see comment above r.e. sed and update-alternatives
-       cp -a ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}
+       cp -R --no-dereference --preserve=mode,links -v ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}
 }
 
 inherit update-alternatives
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +2 -2
index 5216c7027c..7c8809a41e 100644
@@ -106,7 +106,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${B}/tests ${D}${PTEST_PATH}/test
-       cp -a ${S}/tests/* ${D}${PTEST_PATH}/test
+       cp -R --no-dereference --preserve=mode,links -v ${B}/tests ${D}${PTEST_PATH}/test
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests/* ${D}${PTEST_PATH}/test
        sed -e 's!../e2fsck/e2fsck!e2fsck!g' -i ${D}${PTEST_PATH}/test/*/expect*
 }
meta/recipes-extended/mdadm/mdadm_4.0.bb +1 -2
index 98a10a8b15..506b0bc315 100644
@@ -55,7 +55,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${S}/tests ${D}${PTEST_PATH}/tests
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests ${D}${PTEST_PATH}/tests
        cp ${S}/test ${D}${PTEST_PATH}
        sed -e 's!sleep 0.*!sleep 1!g; s!/var/tmp!/!g' -i ${D}${PTEST_PATH}/test
        ln -s ${base_sbindir}/mdadm ${D}${PTEST_PATH}/mdadm
--

2.13.0

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#4 lore raw

I cannot find the exact message in MLs, but this combination of parameters was suggested by someone and approved by others back in 2015, when I did this change and similar in other layers like:
https://patchwork.openembedded.org/patch/116525/

So I'm just using the same everywhere.

But I'm open to change it to some other form if there are technical reasons to do so (other than personal preference).

Quoted 97 lines · Andre McCurdy
Quoted 2 lines · Mark Hatle
Quoted 1 line · Andre McCurdy

On Tue, May 30, 2017 at 1:08 AM, Martin Jansa <[email protected]>

Quoted 4 lines · wrote:
Quoted 4 lines
Quoted 4 lines

* Using "cp -a" leaks UID of user running the builds, causing many QA warnings.
* See this thread for details:
http://lists.openembedded.org/pipermail/openembedded-core/

2015-November/112904.html

Quoted 4 lines
Quoted 2 lines

Using "cp -av --no-preserve=ownership" is a slightly cleaner solution.

I personally prefer Martin's version since '-a' is not supported

everywhere.

Quoted 1 line

(Unless you using gnu cp, which 99% of the Linux world uses.. but

non-Linux

Quoted 1 line

systems rarely do.)

Which versions of cp do you know of that support
"--preserve=mode,links" without supporting "-a" ?

A quick google of manpages suggests that FreeBSD supports "-a" but not "--preserve=XXX". OpenBSD doesn't seem to support either.

Which non-Linux host systems does OE support?

Quoted 10 lines

--Mark

Quoted 8 lines

Review

Quoted 8 lines
---
 meta/recipes-core/coreutils/coreutils_8.27.bb       | 2 +-
 meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb | 4 ++--
 meta/recipes-extended/mdadm/mdadm_4.0.bb            | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)
(quoted diff) +0 -0

b/meta/recipes-core/coreutils/coreutils_8.27.bb

Quoted 6 lines
Quoted 6 lines

meta/recipes-core/coreutils/coreutils_8.27.bb do_install_append() { · line 100

Quoted 6 lines

index 667e0af560..ea8740a2d1 100644

meta/recipes-core/coreutils/coreutils_8.27.bb +0 -0
@@ -99,7 +99,7 @@ do_install_append() {
        install -t ${D}/${mandir}/man1 ${S}/man/*.1
        # prebuilt man pages don't do a separate man page for [ vs

test.

Quoted 2 lines
Quoted 2 lines

meta/recipes-core/coreutils/coreutils_8.27.bb do_install_append() { · line 102

Quoted 2 lines
meta/recipes-core/coreutils/coreutils_8.27.bb +0 -1
        # see comment above r.e. sed and update-alternatives
-       cp -a ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.

${BPN}

Quoted 1 line
Quoted 1 line

meta/recipes-core/coreutils/coreutils_8.27.bb do_install_append() { · line 102

Quoted 1 line
meta/recipes-core/coreutils/coreutils_8.27.bb +1 -0
+       cp -R --no-dereference --preserve=mode,links -v

${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}

Quoted 4 lines
Quoted 4 lines

Review

Quoted 4 lines
meta/recipes-core/coreutils/coreutils_8.27.bb +0 -0
 }
 
 inherit update-alternatives
(quoted diff) +0 -0

b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb

Quoted 10 lines
Quoted 10 lines

meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb do_compile_ptest() { · line 109

Quoted 10 lines

index 5216c7027c..7c8809a41e 100644

meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +1 -2
@@ -106,7 +106,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${B}/tests ${D}${PTEST_PATH}/test
-       cp -a ${S}/tests/* ${D}${PTEST_PATH}/test
+       cp -R --no-dereference --preserve=mode,links -v ${B}/tests

${D}${PTEST_PATH}/test

Quoted 1 line
Quoted 1 line

meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb do_compile_ptest() { · line 110

Quoted 1 line
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +1 -0
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests/*

${D}${PTEST_PATH}/test

Quoted 1 line
Quoted 1 line

meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb do_compile_ptest() { · line 111

Quoted 1 line
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +0 -0
        sed -e 's!../e2fsck/e2fsck!e2fsck!g' -i

${D}${PTEST_PATH}/test/*/expect*

Quoted 2 lines
Quoted 2 lines

Review

Quoted 2 lines
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +0 -0
 }
(quoted diff) +0 -0

b/meta/recipes-extended/mdadm/mdadm_4.0.bb

Quoted 9 lines
Quoted 9 lines

meta/recipes-extended/mdadm/mdadm_4.0.bb do_compile_ptest() { · line 58

Quoted 9 lines

index 98a10a8b15..506b0bc315 100644

meta/recipes-extended/mdadm/mdadm_4.0.bb +1 -1
@@ -55,7 +55,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${S}/tests ${D}${PTEST_PATH}/tests
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests

${D}${PTEST_PATH}/tests

Quoted 2 lines
Quoted 2 lines

meta/recipes-extended/mdadm/mdadm_4.0.bb do_compile_ptest() { · line 60

Quoted 2 lines
meta/recipes-extended/mdadm/mdadm_4.0.bb +0 -0
        cp ${S}/test ${D}${PTEST_PATH}
        sed -e 's!sleep 0.*!sleep 1!g; s!/var/tmp!/!g' -i

${D}${PTEST_PATH}/test

Quoted 10 lines
Quoted 9 lines
Quoted 9 lines
meta/recipes-extended/mdadm/mdadm_4.0.bb +0 -1
        ln -s ${base_sbindir}/mdadm ${D}${PTEST_PATH}/mdadm
--

2.13.0

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#5 lore raw

There are few more QA warnings about this even with this change applied:

count: 3 issue: host-user-contaminated
glibc-locale-2.25: glibc-locale:
/glibc-binary-localedata-ar-jo/usr/lib/locale/ar_JO/LC_PAPER is owned
by uid 3004, which is the same as the user running bitbake. This may
be due to host contamination [host-user-contaminated]
glibc-locale-2.25: glibc-locale:
/glibc-binary-localedata-de-at/usr/lib/locale/de_AT/LC_MEASUREMENT is
owned by uid 3004, which is the same as the user running bitbake. This
may be due to host contamination [host-user-contaminated]
glibc-locale-2.25: glibc-locale:
/glibc-binary-localedata-es-sv.iso-8859-1/usr/lib/locale/es_SV.ISO-8859-1/LC_MESSAGES/SYS_LC_MESSAGES is owned by uid 3004, which is the same as the user running bitbake.
This may be due to host contamination [host-user-contaminated]

These seem to be a bit undeterministic (I think I've seen various locales and files there in different runs, not just these 3 files). But I'll leave this to someone else.

Quoted 112 lines · Martin Jansa

I cannot find the exact message in MLs, but this combination of parameters was suggested by someone and approved by others back in 2015, when I did this change and similar in other layers like:
https://patchwork.openembedded.org/patch/116525/

So I'm just using the same everywhere.

But I'm open to change it to some other form if there are technical reasons to do so (other than personal preference).

Quoted 97 lines · Andre McCurdy
Quoted 2 lines · Mark Hatle
Quoted 1 line · Andre McCurdy

On Tue, May 30, 2017 at 1:08 AM, Martin Jansa <[email protected]>

Quoted 4 lines · wrote:
Quoted 4 lines
Quoted 4 lines

* Using "cp -a" leaks UID of user running the builds, causing many QA warnings.
* See this thread for details:
http://lists.openembedded.org/pipermail/openembedded-

core/2015-November/112904.html

Quoted 4 lines
Quoted 2 lines

Using "cp -av --no-preserve=ownership" is a slightly cleaner solution.

I personally prefer Martin's version since '-a' is not supported

everywhere.

Quoted 1 line

(Unless you using gnu cp, which 99% of the Linux world uses.. but

non-Linux

Quoted 1 line

systems rarely do.)

Which versions of cp do you know of that support
"--preserve=mode,links" without supporting "-a" ?

A quick google of manpages suggests that FreeBSD supports "-a" but not "--preserve=XXX". OpenBSD doesn't seem to support either.

Which non-Linux host systems does OE support?

Quoted 10 lines

--Mark

Quoted 8 lines

Review

Quoted 8 lines
---
 meta/recipes-core/coreutils/coreutils_8.27.bb       | 2 +-
 meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb | 4 ++--
 meta/recipes-extended/mdadm/mdadm_4.0.bb            | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)
(quoted diff) +0 -0

b/meta/recipes-core/coreutils/coreutils_8.27.bb

Quoted 6 lines
Quoted 6 lines

meta/recipes-core/coreutils/coreutils_8.27.bb do_install_append() { · line 100

Quoted 6 lines

index 667e0af560..ea8740a2d1 100644

meta/recipes-core/coreutils/coreutils_8.27.bb +0 -0
@@ -99,7 +99,7 @@ do_install_append() {
        install -t ${D}/${mandir}/man1 ${S}/man/*.1
        # prebuilt man pages don't do a separate man page for [ vs

test.

Quoted 2 lines
Quoted 2 lines

meta/recipes-core/coreutils/coreutils_8.27.bb do_install_append() { · line 102

Quoted 2 lines
meta/recipes-core/coreutils/coreutils_8.27.bb +0 -1
        # see comment above r.e. sed and update-alternatives
-       cp -a ${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.

${BPN}

Quoted 1 line
Quoted 1 line

meta/recipes-core/coreutils/coreutils_8.27.bb do_install_append() { · line 102

Quoted 1 line
meta/recipes-core/coreutils/coreutils_8.27.bb +1 -0
+       cp -R --no-dereference --preserve=mode,links -v

${D}${mandir}/man1/test.1 ${D}${mandir}/man1/lbracket.1.${BPN}

Quoted 4 lines
Quoted 4 lines

Review

Quoted 4 lines
meta/recipes-core/coreutils/coreutils_8.27.bb +0 -0
 }
 
 inherit update-alternatives
(quoted diff) +0 -0

b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb

Quoted 10 lines
Quoted 10 lines

meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb do_compile_ptest() { · line 109

Quoted 10 lines

index 5216c7027c..7c8809a41e 100644

meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +1 -2
@@ -106,7 +106,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${B}/tests ${D}${PTEST_PATH}/test
-       cp -a ${S}/tests/* ${D}${PTEST_PATH}/test
+       cp -R --no-dereference --preserve=mode,links -v ${B}/tests

${D}${PTEST_PATH}/test

Quoted 1 line
Quoted 1 line

meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb do_compile_ptest() { · line 110

Quoted 1 line
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +1 -0
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests/*

${D}${PTEST_PATH}/test

Quoted 1 line
Quoted 1 line

meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb do_compile_ptest() { · line 111

Quoted 1 line
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +0 -0
        sed -e 's!../e2fsck/e2fsck!e2fsck!g' -i

${D}${PTEST_PATH}/test/*/expect*

Quoted 2 lines
Quoted 2 lines

Review

Quoted 2 lines
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.43.4.bb +0 -0
 }
(quoted diff) +0 -0

b/meta/recipes-extended/mdadm/mdadm_4.0.bb

Quoted 9 lines
Quoted 9 lines

meta/recipes-extended/mdadm/mdadm_4.0.bb do_compile_ptest() { · line 58

Quoted 9 lines

index 98a10a8b15..506b0bc315 100644

meta/recipes-extended/mdadm/mdadm_4.0.bb +1 -1
@@ -55,7 +55,7 @@ do_compile_ptest() {
 }
 
 do_install_ptest() {
-       cp -a ${S}/tests ${D}${PTEST_PATH}/tests
+       cp -R --no-dereference --preserve=mode,links -v ${S}/tests

${D}${PTEST_PATH}/tests

Quoted 2 lines
Quoted 2 lines

meta/recipes-extended/mdadm/mdadm_4.0.bb do_compile_ptest() { · line 60

Quoted 2 lines
meta/recipes-extended/mdadm/mdadm_4.0.bb +0 -0
        cp ${S}/test ${D}${PTEST_PATH}
        sed -e 's!sleep 0.*!sleep 1!g; s!/var/tmp!/!g' -i

${D}${PTEST_PATH}/test

Quoted 10 lines
Quoted 9 lines
Quoted 9 lines
meta/recipes-extended/mdadm/mdadm_4.0.bb +0 -1
        ln -s ${base_sbindir}/mdadm ${D}${PTEST_PATH}/mdadm
--

2.13.0

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#6 lore raw
Quoted 17 lines · Martin Jansa

There are few more QA warnings about this even with this change applied:

count: 3 issue: host-user-contaminated
glibc-locale-2.25: glibc-locale: /glibc-binary-localedata-ar- jo/usr/lib/locale/ar_JO/LC_PAPER is owned by uid 3004, which is the same as the user running bitbake. This may be due to host contamination [host-user-contaminated]
glibc-locale-2.25: glibc-locale: /glibc-binary-localedata-de- at/usr/lib/locale/de_AT/LC_MEASUREMENT is owned by uid 3004, which is the same as the user running bitbake. This may be due to host contamination [host-user-contaminated]
glibc-locale-2.25: glibc-locale: /glibc-binary-localedata-es-sv.iso- 8859-1/usr/lib/locale/es_SV.ISO-8859-1/LC_MESSAGES/SYS_LC_MESSAGES is owned by uid 3004, which is the same as the user running bitbake. This may be due to host contamination [host-user-contaminated]

Quoted 3 lines

These seem to be a bit undeterministic (I think I've seen various locales and files there in different runs, not just these 3 files). But I'll leave this to someone else.

I think there is an open bug for this one:

https://bugzilla.yoctoproject.org/show_bug.cgi?id=11299

Cheers,

Richard