perl: fix re-execution of task
Quoted 1 line
---
a/meta/recipes-devtools/perl/perl_5.14.2.bb
Quoted 1 line
+++
b/meta/recipes-devtools/perl/perl_5.14.2.bb
Review
Quoted 1 line
(quoted diff) +0
-0@@ -164,8 +164,12 @@
do_configure() {
Review line 165
Quoted 2 lines
(quoted diff) +0
-0esac # These are strewn all over the source
tree
Review line 166
Quoted 1 line
(quoted diff) +0
-0for foo in `grep -I -m1 \/usr\/include\/.*\\.h ${WORKDIR}/*
-r | cut -f 1 -d ":"` ; do
Review line 168
Quoted 2 lines
(quoted diff) +0
-2- echo Fixing: $foo -
sed -e "s%/usr/include/%${STAGING_INCDIR}/%g" -i $foo
Review line 167
Quoted 1 line
(quoted diff) +1
-0+ # D2194:Fixing
the issue "patch file link is replaced with modified file"
Review line 168
Quoted 1 line
(quoted diff) +1
-0+ # Ignore if
file is a link, as actual file will also get caught during grep
Review line 169
Quoted 1 line
(quoted diff) +1
-0+ if [
! -h $foo ]; then
Review line 171
Quoted 2 lines
(quoted diff) +2
-0+ echo Fixing: $foo + sed -e
"s%/usr/include/%${STAGING_INCDIR}/%g" -i $foo
Review line 172
Quoted 1 line
(quoted diff) +1
-0+ fi
From: Richard Purdie <[email protected]>
To: Venkata ramana gollamudi <[email protected]>
Cc: "'[email protected]'"
<[email protected]>, Sanil kumar <[email protected]>
Date: Fri, 13 Apr 2012 16:29:36 +0100
In-Reply-To: <36ED13F3654AE54CA763E6821D93A5711043A0F7@szxeml534-mbs.china.huawei.com> References:
<36ED13F3654AE54CA763E6821D93A5711043A0F7@szxeml534-mbs.china.huawei.com>
Content-Type: text/plain; charset="UTF-8"
X-Mailer: Evolution 3.2.2-
Content-Transfer-Encoding: 7bit
Mime-Version: 1.0
Quoted 25 lines · Venkata ramana gollamudi
perl package
do_configureis changing "/perl-5.14.2/patches/h2ph-multiarch.diff"
from link to normal file in the process of correcting the paths.
So when patch task is re-executed after complete package building, giving error.This path correction is not required for links as the link target file
will be also be modified individually.
Fix done to ignore the path correction duringdo_configure,
if file is a link.[Yocto #2194]
Signed-off-by Venkata Ramana Gollamudi <[email protected]>--- meta/recipes-devtools/perl/perl_5.14.2.bb | 8 ++++++-- 1 files changed, 6 insertions(+), 2 deletions(-)meta/recipes-devtools/perl/perl_5.14.2.bb +0
-1@@ -164,8 +164,12 @@ do_configure() { esac # These are strewn all over the source tree for foo in `grep -I -m1 \/usr\/include\/.*\\.h ${WORKDIR}/* -r | cut -f 1 -d ":"` ; do - echo Fixing: $foo
meta/recipes-devtools/perl/perl_5.14.2.bb do_configure() { · line 175
Quoted 10 lines
meta/recipes-devtools/perl/perl_5.14.2.bb +6
-1- sed -e "s%/usr/include/%${STAGING_INCDIR}/%g" -i $foo + # D2194:Fixing the issue "patch file link is replaced with modified file" + # Ignore if file is a link, as actual file will also get caught during grep + if [ ! -h $foo ]; then + echo Fixing: $foo + sed -e "s%/usr/include/%${STAGING_INCDIR}/%g" -i $foo + fi done rm -f config
I think its a bad idea to assume patches are symlinks. Could we add something like --exclude=patches to the grep command?
Secondly, the above will still cause problems if ${STAGING_INCDIR} contains /usr/include which it usually will, for example if:
STAGING_INCDIR=/foo/usr/include
then you can end up with:
/foo/foo/foo/foo/usr/include
after a few runs. This fix therefore still needs some work.
Cheers,
Richard