Skip to contentSkip to conversation

qt4: fix sed to have correct *.pc files

PATCH Applied Eric Bénard 3 participants 3 messages Nov 29, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 qt4: fix sed to have correct *.pc files

it seems sed doesn't handle \? properly if the string in not between quotes.

without this patch, we get something like (for example for QtDBusE.pc :
Libs: -L${libdir} -lQtDBusE
Libs.private: -L/home/ebenard/WORK/setup-scripts/build/tmp-angstrom_2010_x-eglibc/sysroots/board/ usr/lib -L/usr/lib -L/home/ebenard/WORK/setup-scripts/build/tmp-angstrom_2010_x-eglibc/sysroots/board /usr/lib -lQtXmlE -L/usr/lib -lQtCoreE -lpthread
Cflags: -DQT_SHARED -I/usr/include/qtopia -I${includedir}

with the patch we get what is expected :
Libs: -L${libdir} -lQtDBusE
Libs.private: -lQtXmlE -lQtCoreE -lpthread
Cflags: -DQT_SHARED -I/usr/include/qtopia -I${includedir}

---
 meta/recipes-qt/qt4/qt4-embedded.inc |    2 +-
 meta/recipes-qt/qt4/qt4-x11-free.inc |    2 +-
 meta/recipes-qt/qt4/qt4.inc          |   10 +++++-----
 3 files changed, 7 insertions(+), 7 deletions(-)
meta/recipes-qt/qt4/qt4-embedded.inc +1 -1
index bee7345..c4f6e98 100644
@@ -3,7 +3,7 @@ SECTION = "libs"
 LICENSE = "LGPLv2.1 | GPLv3"
 HOMEPAGE = "http://qt.nokia.com"
 DEPENDS += "directfb tslib"
-INC_PR = "r36"
+INC_PR = "r37"
 
 QT_BASE_NAME ?= "qt4-embedded"
 QT_BASE_LIB  ?= "libqt-embedded"
meta/recipes-qt/qt4/qt4-x11-free.inc +1 -1
index f391028..5abb5a1 100644
@@ -5,7 +5,7 @@ HOMEPAGE = "http://qt.nokia.com"
 SECTION = "x11/libs"
 DEPENDS += "virtual/libgl virtual/libx11 fontconfig libxft libxext libxrender libxrandr libxcursor"
 
-INC_PR = "r32"
+INC_PR = "r33"
 
 QT_GLFLAGS ?= "${@base_contains('DISTRO_FEATURES', 'opengl', '-opengl', '-no-opengl', d)} "
 QT_GLFLAGS_qemux86 = "-opengl"
meta/recipes-qt/qt4/qt4.inc +5 -5
index 82ba637..b365e75 100644
@@ -294,13 +294,13 @@ do_install() {
 	rm -f ${D}/${bindir}/lrelease
 
 	# fix pkgconfig, libtool and prl files
-	sed -i -e s#-L${S}/lib/\?##g \
-			-e s#-L${STAGING_LIBDIR}/\?##g \
+	sed -i -e 's#-L${S}/lib/\?##g' \
+			-e 's#-L${STAGING_LIBDIR}/\?##g' \
 			-e 's#STAGING_LIBDIR}#libdir}'#g \
-			-e s#-L${libdir}/\?##g \
+			-e 's#-L${libdir}/\?##g' \
 			-e s#'$(OE_QMAKE_LIBS_X11)'#"${OE_QMAKE_LIBS_X11}"#g \
-			-e s#" -Wl,-rpath-link,${S}/lib/\?"##g \
-			-e s#" -Wl,-rpath-link,${libdir}/\?"##g \
+			-e 's#" -Wl,-rpath-link,${S}/lib/\?"##g' \
+			-e 's#" -Wl,-rpath-link,${libdir}/\?"##g' \
 			-e 's#Iin#I${in#g' \
 			${D}${libdir}/*.la ${D}${libdir}/*.prl ${D}${libdir}/pkgconfig/*.pc
 
Signature · 1 line
1.7.6.4
Acked-by on v1 1/1
#1 lore raw
Quoted 88 lines · Eric Bénard

it seems sed doesn't handle \? properly if the string in not between quotes.

without this patch, we get something like (for example for QtDBusE.pc :
Libs: -L${libdir} -lQtDBusE
Libs.private:
-L/home/ebenard/WORK/setup-scripts/build/tmp-angstrom_2010_x-eglibc/sysroots/board/ usr/lib -L/usr/lib
-L/home/ebenard/WORK/setup-scripts/build/tmp-angstrom_2010_x-eglibc/sysroots/board
/usr/lib -lQtXmlE -L/usr/lib -lQtCoreE -lpthread
Cflags: -DQT_SHARED -I/usr/include/qtopia -I${includedir}

with the patch we get what is expected :
Libs: -L${libdir} -lQtDBusE
Libs.private: -lQtXmlE -lQtCoreE -lpthread
Cflags: -DQT_SHARED -I/usr/include/qtopia -I${includedir}

---
 meta/recipes-qt/qt4/qt4-embedded.inc |    2 +-
 meta/recipes-qt/qt4/qt4-x11-free.inc |    2 +-
 meta/recipes-qt/qt4/qt4.inc          |   10 +++++-----
 3 files changed, 7 insertions(+), 7 deletions(-)
meta/recipes-qt/qt4/qt4-embedded.inc +1 -1
index bee7345..c4f6e98 100644
@@ -3,7 +3,7 @@ SECTION = "libs"
 LICENSE = "LGPLv2.1 | GPLv3"
 HOMEPAGE = "http://qt.nokia.com"
 DEPENDS += "directfb tslib"
-INC_PR = "r36"
+INC_PR = "r37"
 
 QT_BASE_NAME ?= "qt4-embedded"
 QT_BASE_LIB  ?= "libqt-embedded"
meta/recipes-qt/qt4/qt4-x11-free.inc +0 -0
index f391028..5abb5a1 100644
@@ -5,7 +5,7 @@ HOMEPAGE = "http://qt.nokia.com"
 SECTION = "x11/libs"
 DEPENDS += "virtual/libgl virtual/libx11 fontconfig libxft libxext

libxrender libxrandr libxcursor"

meta/recipes-qt/qt4/qt4-x11-free.inc +1 -1
-INC_PR = "r32"
+INC_PR = "r33"
 
 QT_GLFLAGS ?= "${@base_contains('DISTRO_FEATURES', 'opengl', '-opengl',

'-no-opengl', d)} "
QT_GLFLAGS_qemux86 = "-opengl"

meta/recipes-qt/qt4/qt4.inc +5 -5
index 82ba637..b365e75 100644
@@ -294,13 +294,13 @@ do_install() {
       rm -f ${D}/${bindir}/lrelease
 
       # fix pkgconfig, libtool and prl files
-       sed -i -e s#-L${S}/lib/\?##g \
-                       -e s#-L${STAGING_LIBDIR}/\?##g \
+       sed -i -e 's#-L${S}/lib/\?##g' \
+                       -e 's#-L${STAGING_LIBDIR}/\?##g' \
                       -e 's#STAGING_LIBDIR}#libdir}'#g \
-                       -e s#-L${libdir}/\?##g \
+                       -e 's#-L${libdir}/\?##g' \
                       -e
 s#'$(OE_QMAKE_LIBS_X11)'#"${OE_QMAKE_LIBS_X11}"#g \
-                       -e s#" -Wl,-rpath-link,${S}/lib/\?"##g \
-                       -e s#" -Wl,-rpath-link,${libdir}/\?"##g \
+                       -e 's#" -Wl,-rpath-link,${S}/lib/\?"##g' \
+                       -e 's#" -Wl,-rpath-link,${libdir}/\?"##g' \
                       -e 's#Iin#I${in#g' \
                       ${D}${libdir}/*.la ${D}${libdir}/*.prl

${D}${libdir}/pkgconfig/*.pc

--
1.7.6.4

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

Signature · 3 lines
Otavio Salvador                             O.S. Systems
E-mail: [email protected]  http://www.ossystems.com.br
Mobile: +55 53 9981-7854              http://projetos.ossystems.com.br
#2 lore raw
In reply to Eric Bénard
Quoted 15 lines · Eric Bénard

it seems sed doesn't handle \? properly if the string in not between quotes.

without this patch, we get something like (for example for QtDBusE.pc :
Libs: -L${libdir} -lQtDBusE
Libs.private: -L/home/ebenard/WORK/setup-scripts/build/tmp-angstrom_2010_x-eglibc/sysroots/board/ usr/lib -L/usr/lib -L/home/ebenard/WORK/setup-scripts/build/tmp-angstrom_2010_x-eglibc/sysroots/board /usr/lib -lQtXmlE -L/usr/lib -lQtCoreE -lpthread
Cflags: -DQT_SHARED -I/usr/include/qtopia -I${includedir}

with the patch we get what is expected :
Libs: -L${libdir} -lQtDBusE
Libs.private: -lQtXmlE -lQtCoreE -lpthread
Cflags: -DQT_SHARED -I/usr/include/qtopia -I${includedir}

Quoted 6 lines
---
 meta/recipes-qt/qt4/qt4-embedded.inc |    2 +-
 meta/recipes-qt/qt4/qt4-x11-free.inc |    2 +-
 meta/recipes-qt/qt4/qt4.inc          |   10 +++++-----
 3 files changed, 7 insertions(+), 7 deletions(-)

Merged to master, thanks.

Richard