* [PATCH 0/1] glib-2.0: fix a host contamination issue
@ 2013-09-03 7:52 Robert Yang
2013-09-03 7:52 ` [PATCH 1/1] " Robert Yang
0 siblings, 1 reply; 7+ messages in thread
From: Robert Yang @ 2013-09-03 7:52 UTC (permalink / raw)
To: openembedded-core
The following changes since commit 5745e45b18e5099e94b4d5a73bc97dc6d4cdc91f:
buildtools-tarball: Add python-pkgutil (2013-08-29 00:23:20 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib robert/glib-2.0
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=robert/glib-2.0
Robert Yang (1):
glib-2.0: fix a host contamination issue
meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
--
1.8.1.2
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 1/1] glib-2.0: fix a host contamination issue
2013-09-03 7:52 [PATCH 0/1] glib-2.0: fix a host contamination issue Robert Yang
@ 2013-09-03 7:52 ` Robert Yang
2013-09-03 9:51 ` Burton, Ross
0 siblings, 1 reply; 7+ messages in thread
From: Robert Yang @ 2013-09-03 7:52 UTC (permalink / raw)
To: openembedded-core
We will see the following warning by accident:
$ bitbake nativesdk-glib-2.0
WARNING: QA Issue: nativesdk-glib-2.0-dbg: found library in wrong location:
/opt/poky/0.5.5/sysroots/x86_64-pokysdk-linux/usr/share/gdb/auto-load/opt/
poky/0.5.5/sysroots/x86_64-pokysdk-linux/usr/lib/libglib-2.0.so.0.3600.4-gdb.py
There are two '/opt/poky/0.5.5/sysroots' in the path when the warning
comes, this is what we need since glib-2.0 has done this intentionally
in its configure and Makefile.
This is because the configure script uses the:
ABS_GLIB_RUNTIME_LIBDIR = "readlink -f $libdir/$with_runtime_libdir`"
to figure out the abs dir, so if
/opt/poky/0.5.5/sysroots/x86_64-pokysdk-linux/usr/lib/ exists , there
would be warning, otherwise no warning.
We can change the "readlink -f" to "readlink -m" to fix the host
contamination issue.
Another fix could be:
ABS_GLIB_RUNTIME_LIBDIR =""
But this is much more like a workaround.
BTW, fix the previous sed command's indent.
[YOCTO #5099]
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb b/meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb
index 0918bf5..cc104cc 100644
--- a/meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb
+++ b/meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb
@@ -47,7 +47,12 @@ RDEPENDS_${PN}-ptest_append_libc-glibc = "\
EXTRA_OECONF_append_class-target_libc-uclibc = " --with-libiconv=gnu"
do_configure_prepend() {
- sed -i -e '1s,#!.*,#!${USRBINPATH}/env python,' ${S}/gio/gdbus-2.0/codegen/gdbus-codegen.in
+ # Change the "readlink -f" to "readlink -m" to fix a host
+ # contamination issue, the later one doesn't require the
+ # components existence.
+ sed -i -e 's/^\(ABS_GLIB_RUNTIME_LIBDIR=.*readlink\) -f/\1 -m/' ${S}/configure.ac
+
+ sed -i -e '1s,#!.*,#!${USRBINPATH}/env python,' ${S}/gio/gdbus-2.0/codegen/gdbus-codegen.in
}
do_install_append() {
--
1.8.1.2
^ permalink raw reply related [flat|nested] 7+ messages in thread* Re: [PATCH 1/1] glib-2.0: fix a host contamination issue
2013-09-03 7:52 ` [PATCH 1/1] " Robert Yang
@ 2013-09-03 9:51 ` Burton, Ross
2013-09-03 11:16 ` Robert Yang
0 siblings, 1 reply; 7+ messages in thread
From: Burton, Ross @ 2013-09-03 9:51 UTC (permalink / raw)
To: Robert Yang; +Cc: OE-core
On 3 September 2013 08:52, Robert Yang <liezhi.yang@windriver.com> wrote:
> + sed -i -e 's/^\(ABS_GLIB_RUNTIME_LIBDIR=.*readlink\) -f/\1 -m/' ${S}/configure.ac
Please do this as a patch instead of a sed.
Ross
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 1/1] glib-2.0: fix a host contamination issue
2013-09-03 9:51 ` Burton, Ross
@ 2013-09-03 11:16 ` Robert Yang
2013-09-03 11:39 ` Tomas Frydrych
0 siblings, 1 reply; 7+ messages in thread
From: Robert Yang @ 2013-09-03 11:16 UTC (permalink / raw)
To: Burton, Ross; +Cc: OE-core
On 09/03/2013 05:51 PM, Burton, Ross wrote:
> On 3 September 2013 08:52, Robert Yang <liezhi.yang@windriver.com> wrote:
>> + sed -i -e 's/^\(ABS_GLIB_RUNTIME_LIBDIR=.*readlink\) -f/\1 -m/' ${S}/configure.ac
>
> Please do this as a patch instead of a sed.
It seems that sed command is preferred ? For example, we don't have to port the
patch once we upgrade glib-2.0.
// Robert
>
> Ross
>
>
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 1/1] glib-2.0: fix a host contamination issue
2013-09-03 11:16 ` Robert Yang
@ 2013-09-03 11:39 ` Tomas Frydrych
2013-09-03 11:48 ` Robert Yang
0 siblings, 1 reply; 7+ messages in thread
From: Tomas Frydrych @ 2013-09-03 11:39 UTC (permalink / raw)
To: openembedded-core
On 03/09/13 12:16, Robert Yang wrote:
>
>
> On 09/03/2013 05:51 PM, Burton, Ross wrote:
>> On 3 September 2013 08:52, Robert Yang <liezhi.yang@windriver.com> wrote:
>>> + sed -i -e 's/^\(ABS_GLIB_RUNTIME_LIBDIR=.*readlink\) -f/\1 -m/'
>>> ${S}/configure.ac
>>
>> Please do this as a patch instead of a sed.
>
> It seems that sed command is preferred ? For example, we don't have to
> port the
> patch once we upgrade glib-2.0.
Having to port a patch when it fails to apply ensures we are still doing
the right thing. In contrast, these sed snippets don't generate errors
when they fail, and they remain in recipes for years when no longer
working/needed.
Tomas
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 1/1] glib-2.0: fix a host contamination issue
2013-09-03 11:39 ` Tomas Frydrych
@ 2013-09-03 11:48 ` Robert Yang
0 siblings, 0 replies; 7+ messages in thread
From: Robert Yang @ 2013-09-03 11:48 UTC (permalink / raw)
To: Tomas Frydrych; +Cc: openembedded-core
On 09/03/2013 07:39 PM, Tomas Frydrych wrote:
> On 03/09/13 12:16, Robert Yang wrote:
>>
>>
>> On 09/03/2013 05:51 PM, Burton, Ross wrote:
>>> On 3 September 2013 08:52, Robert Yang <liezhi.yang@windriver.com> wrote:
>>>> + sed -i -e 's/^\(ABS_GLIB_RUNTIME_LIBDIR=.*readlink\) -f/\1 -m/'
>>>> ${S}/configure.ac
>>>
>>> Please do this as a patch instead of a sed.
>>
>> It seems that sed command is preferred ? For example, we don't have to
>> port the
>> patch once we upgrade glib-2.0.
>
> Having to port a patch when it fails to apply ensures we are still doing
> the right thing. In contrast, these sed snippets don't generate errors
> when they fail, and they remain in recipes for years when no longer
> working/needed.
>
Thanks, I will send a V2.
// Robert
> Tomas
>
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
>
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 0/1 V2] glib-2.0: fix a host contamination issue
@ 2013-09-03 12:37 Robert Yang
2013-09-03 12:37 ` [PATCH 1/1] " Robert Yang
0 siblings, 1 reply; 7+ messages in thread
From: Robert Yang @ 2013-09-03 12:37 UTC (permalink / raw)
To: openembedded-core
* Changes of V2:
- Use the patch to modify the file instead of the sed command.
// Robert
The following changes since commit 755f7d9afaab4e7424f5f57587aa45df3807acf0:
pulseaudio: disable GTK+ by default (2013-09-02 18:04:59 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib robert/glib-2.0
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=robert/glib-2.0
Robert Yang (1):
glib-2.0: fix a host contamination issue
.../glib-2.0/glib-2.0-configure-readlink.patch | 29 ++++++++++++++++++++++
meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb | 1 +
2 files changed, 30 insertions(+)
create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/glib-2.0-configure-readlink.patch
--
1.8.1.2
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 1/1] glib-2.0: fix a host contamination issue
2013-09-03 12:37 [PATCH 0/1 V2] " Robert Yang
@ 2013-09-03 12:37 ` Robert Yang
0 siblings, 0 replies; 7+ messages in thread
From: Robert Yang @ 2013-09-03 12:37 UTC (permalink / raw)
To: openembedded-core
We will see the following warning by accident:
$ bitbake nativesdk-glib-2.0
WARNING: QA Issue: nativesdk-glib-2.0-dbg: found library in wrong location:
/opt/poky/0.5.5/sysroots/x86_64-pokysdk-linux/usr/share/gdb/auto-load/opt/
poky/0.5.5/sysroots/x86_64-pokysdk-linux/usr/lib/libglib-2.0.so.0.3600.4-gdb.py
There are two '/opt/poky/0.5.5/sysroots' in the path when the warning
comes, this is what we need since glib-2.0 has done this intentionally
in its configure and Makefile.
This is because the configure script uses the:
ABS_GLIB_RUNTIME_LIBDIR = "readlink -f $libdir/$with_runtime_libdir`"
to figure out the abs dir, so if
/opt/poky/0.5.5/sysroots/x86_64-pokysdk-linux/usr/lib/ exists , there
would be warning, otherwise no warning.
We can change the "readlink -f" to "readlink -m" to fix the host
contamination issue.
Another fix could be:
ABS_GLIB_RUNTIME_LIBDIR =""
But this is much more like a workaround.
[YOCTO #5099]
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
.../glib-2.0/glib-2.0-configure-readlink.patch | 29 ++++++++++++++++++++++
meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb | 1 +
2 files changed, 30 insertions(+)
create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/glib-2.0-configure-readlink.patch
diff --git a/meta/recipes-core/glib-2.0/glib-2.0/glib-2.0-configure-readlink.patch b/meta/recipes-core/glib-2.0/glib-2.0/glib-2.0-configure-readlink.patch
new file mode 100644
index 0000000..9759d11
--- /dev/null
+++ b/meta/recipes-core/glib-2.0/glib-2.0/glib-2.0-configure-readlink.patch
@@ -0,0 +1,29 @@
+configure.ac: change readlink -f to -m
+
+Change "readlink -f" to "readlink -m" since $libdir/$with_runtime_libdir
+may not exist.
+
+This patch should go to the upstream, I will send it sooner.
+
+Upstream-Status: Pending
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+--- a/configure.ac
++++ b/configure.ac
+@@ -271,7 +271,7 @@ AC_ARG_WITH(runtime-libdir,
+ [],
+ [with_runtime_libdir=""])
+ GLIB_RUNTIME_LIBDIR="$with_runtime_libdir"
+-ABS_GLIB_RUNTIME_LIBDIR="`readlink -f $libdir/$with_runtime_libdir`"
++ABS_GLIB_RUNTIME_LIBDIR="`readlink -m $libdir/$with_runtime_libdir`"
+ AC_SUBST(GLIB_RUNTIME_LIBDIR)
+ AC_SUBST(ABS_GLIB_RUNTIME_LIBDIR)
+ AM_CONDITIONAL(HAVE_GLIB_RUNTIME_LIBDIR, [test "x$with_runtime_libdir" != "x"])
+--
+1.8.1.2
+
diff --git a/meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb b/meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb
index 0918bf5..d62c1fd 100644
--- a/meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb
+++ b/meta/recipes-core/glib-2.0/glib-2.0_2.36.4.bb
@@ -15,6 +15,7 @@ SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \
file://Makefile-ptest.patch \
file://add-march-i486-into-CFLAGS-automatically.patch \
file://run-ptest \
+ file://glib-2.0-configure-readlink.patch \
"
SRC_URI_append_class-native = " file://glib-gettextize-dir.patch"
--
1.8.1.2
^ permalink raw reply related [flat|nested] 7+ messages in thread
end of thread, other threads:[~2013-09-03 12:41 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-03 7:52 [PATCH 0/1] glib-2.0: fix a host contamination issue Robert Yang
2013-09-03 7:52 ` [PATCH 1/1] " Robert Yang
2013-09-03 9:51 ` Burton, Ross
2013-09-03 11:16 ` Robert Yang
2013-09-03 11:39 ` Tomas Frydrych
2013-09-03 11:48 ` Robert Yang
-- strict thread matches above, loose matches on Subject: below --
2013-09-03 12:37 [PATCH 0/1 V2] " Robert Yang
2013-09-03 12:37 ` [PATCH 1/1] " Robert Yang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox