Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] qt4: remove trailing slash from prefix
@ 2013-05-07  9:05 Paul Barker
  2013-05-08 18:07 ` Paul Barker
  0 siblings, 1 reply; 4+ messages in thread
From: Paul Barker @ 2013-05-07  9:05 UTC (permalink / raw)
  To: openembedded-core

The trailing slashs on "Prefix=${prefix}/" and "-prefix ${prefix}/" are passed
through to the generated pkgconfig files and may be joined to paths like
"/include" yielding a final path with a double forward-slash (eg.
"/usr//include"). This may end up in the debugging symbols in other applications
or libraries which depend on qt4 which in turn causes the debugedit program to
fail with the message "canonicalization unexpectedly shrank by one character"
when it tries to replace the double forward-slash with a single forward-slash.
Thus the function split_and_strip_files fails and ultimately do_package fails.

As this slash is removed from the prefix it is added into the regular expression
used to fix up pkgconfig files later in the recipe.

This error was seen in vlc in meta-openembedded and should be solved by this
change in openembedded-core.

Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
---
 meta/recipes-qt/qt4/qt4.inc | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-qt/qt4/qt4.inc b/meta/recipes-qt/qt4/qt4.inc
index 37fc1dd..84c0ae9 100644
--- a/meta/recipes-qt/qt4/qt4.inc
+++ b/meta/recipes-qt/qt4/qt4.inc
@@ -213,7 +213,7 @@ do_configure() {
 	cp -f ${WORKDIR}/linux.conf mkspecs/common/
 
 	echo "[Paths]"                                 > $QT_CONF_PATH
-	echo "Prefix=${prefix}/"                      >> $QT_CONF_PATH
+	echo "Prefix=${prefix}"                       >> $QT_CONF_PATH
 	echo "Documentation=${docdir}/${QT_DIR_NAME}" >> $QT_CONF_PATH
 	echo "Headers=${includedir}/${QT_DIR_NAME}"   >> $QT_CONF_PATH
 	echo "Libraries=${libdir}"                    >> $QT_CONF_PATH
@@ -229,7 +229,7 @@ do_configure() {
 	${EXTRA_QMAKE_MUNGE}|| true
 
 	echo yes | QT_LICENSE_FILE="${QT_LICENSE_FILE}" ./configure -v \
-			-prefix ${prefix}/ \
+			-prefix ${prefix} \
 			-bindir ${bindir} \
 			-libdir ${libdir} \
 			-datadir ${datadir}/${QT_DIR_NAME} \
@@ -358,7 +358,7 @@ do_install() {
 
 	# QT abuses $includedir to point to its headers, which breaks pkgconfig sysroot, so manually fix it up here:
 	for pc in ${D}${libdir}/pkgconfig/*.pc ; do
-		sed -i -e "s:prefix}include/${QT_DIR_NAME}/$(basename $pc .pc):prefix}/include:" \
+		sed -i -e "s:prefix}/include/${QT_DIR_NAME}/$(basename $pc .pc):prefix}/include:" \
 				-e 's:IP{:I${:g' $pc
 	done
 
-- 
1.8.2.2




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

* Re: [PATCH] qt4: remove trailing slash from prefix
  2013-05-07  9:05 [PATCH] qt4: remove trailing slash from prefix Paul Barker
@ 2013-05-08 18:07 ` Paul Barker
  2013-05-08 19:14   ` Martin Jansa
  0 siblings, 1 reply; 4+ messages in thread
From: Paul Barker @ 2013-05-08 18:07 UTC (permalink / raw)
  To: openembedded-core; +Cc: Martin Jansa

On 7 May 2013 10:05, Paul Barker <paul@paulbarker.me.uk> wrote:
> The trailing slashs on "Prefix=${prefix}/" and "-prefix ${prefix}/" are passed
> through to the generated pkgconfig files and may be joined to paths like
> "/include" yielding a final path with a double forward-slash (eg.
> "/usr//include"). This may end up in the debugging symbols in other applications
> or libraries which depend on qt4 which in turn causes the debugedit program to
> fail with the message "canonicalization unexpectedly shrank by one character"
> when it tries to replace the double forward-slash with a single forward-slash.
> Thus the function split_and_strip_files fails and ultimately do_package fails.
>
> As this slash is removed from the prefix it is added into the regular expression
> used to fix up pkgconfig files later in the recipe.
>
> This error was seen in vlc in meta-openembedded and should be solved by this
> change in openembedded-core.
>
> Signed-off-by: Paul Barker <paul@paulbarker.me.uk>

Martin, could you check whether applying this patch to oe-core fixes
the vlc do_package failure you were seeing?

Thanks,

--
Paul Barker

Email: paul@paulbarker.me.uk
http://www.paulbarker.me.uk



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

* Re: [PATCH] qt4: remove trailing slash from prefix
  2013-05-08 18:07 ` Paul Barker
@ 2013-05-08 19:14   ` Martin Jansa
  2013-05-19  7:59     ` Martin Jansa
  0 siblings, 1 reply; 4+ messages in thread
From: Martin Jansa @ 2013-05-08 19:14 UTC (permalink / raw)
  To: Paul Barker; +Cc: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 1505 bytes --]

On Wed, May 08, 2013 at 07:07:57PM +0100, Paul Barker wrote:
> On 7 May 2013 10:05, Paul Barker <paul@paulbarker.me.uk> wrote:
> > The trailing slashs on "Prefix=${prefix}/" and "-prefix ${prefix}/" are passed
> > through to the generated pkgconfig files and may be joined to paths like
> > "/include" yielding a final path with a double forward-slash (eg.
> > "/usr//include"). This may end up in the debugging symbols in other applications
> > or libraries which depend on qt4 which in turn causes the debugedit program to
> > fail with the message "canonicalization unexpectedly shrank by one character"
> > when it tries to replace the double forward-slash with a single forward-slash.
> > Thus the function split_and_strip_files fails and ultimately do_package fails.
> >
> > As this slash is removed from the prefix it is added into the regular expression
> > used to fix up pkgconfig files later in the recipe.
> >
> > This error was seen in vlc in meta-openembedded and should be solved by this
> > change in openembedded-core.
> >
> > Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
> 
> Martin, could you check whether applying this patch to oe-core fixes
> the vlc do_package failure you were seeing?

Yes I plan to include it in next build, but I would like to fix
webkit-efl build with newer binutils first, because that adds 3.9M lines 
from log.do_compile and resulting logs from world have 600M :/

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 205 bytes --]

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

* Re: [PATCH] qt4: remove trailing slash from prefix
  2013-05-08 19:14   ` Martin Jansa
@ 2013-05-19  7:59     ` Martin Jansa
  0 siblings, 0 replies; 4+ messages in thread
From: Martin Jansa @ 2013-05-19  7:59 UTC (permalink / raw)
  To: Paul Barker; +Cc: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 1646 bytes --]

On Wed, May 08, 2013 at 09:14:16PM +0200, Martin Jansa wrote:
> On Wed, May 08, 2013 at 07:07:57PM +0100, Paul Barker wrote:
> > On 7 May 2013 10:05, Paul Barker <paul@paulbarker.me.uk> wrote:
> > > The trailing slashs on "Prefix=${prefix}/" and "-prefix ${prefix}/" are passed
> > > through to the generated pkgconfig files and may be joined to paths like
> > > "/include" yielding a final path with a double forward-slash (eg.
> > > "/usr//include"). This may end up in the debugging symbols in other applications
> > > or libraries which depend on qt4 which in turn causes the debugedit program to
> > > fail with the message "canonicalization unexpectedly shrank by one character"
> > > when it tries to replace the double forward-slash with a single forward-slash.
> > > Thus the function split_and_strip_files fails and ultimately do_package fails.
> > >
> > > As this slash is removed from the prefix it is added into the regular expression
> > > used to fix up pkgconfig files later in the recipe.
> > >
> > > This error was seen in vlc in meta-openembedded and should be solved by this
> > > change in openembedded-core.
> > >
> > > Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
> > 
> > Martin, could you check whether applying this patch to oe-core fixes
> > the vlc do_package failure you were seeing?
> 
> Yes I plan to include it in next build, but I would like to fix
> webkit-efl build with newer binutils first, because that adds 3.9M lines 
> from log.do_compile and resulting logs from world have 600M :/

Yes it fixed it, thanks!

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 205 bytes --]

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

end of thread, other threads:[~2013-05-19  8:18 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-07  9:05 [PATCH] qt4: remove trailing slash from prefix Paul Barker
2013-05-08 18:07 ` Paul Barker
2013-05-08 19:14   ` Martin Jansa
2013-05-19  7:59     ` Martin Jansa

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox