* web2 on PPC
@ 2011-09-30 20:15 Gary Thomas
2011-10-03 14:59 ` Gary Thomas
2011-10-03 15:50 ` Holger Hans Peter Freyther
0 siblings, 2 replies; 12+ messages in thread
From: Gary Thomas @ 2011-09-30 20:15 UTC (permalink / raw)
To: Poky Project
I'm trying to run the web-webkit browser on my PowerPC system (built using Poky).
I've built this on ARM and it runs great, but on PowerPC it fails almost immediately.
Following into the failure with GDB, it looks like it's trying to build up a string
using a [possibly] wide character iterator. It fails on line 76 of the code below,
going through it by hand shows that 'iterator' is NULL.
(gdb) dir /local/logopak8347tbga_new/tmp/work/ppc603e-amltd-linux/webkit-gtk-1.5.1+svnr90727-r0
(gdb) l
71 TextBreakIterator* acquireLineBreakIterator(const UChar* string, int length, const AtomicString& locale)
72 {
73 UBreakIterator* iterator = LineBreakIteratorPool::sharedPool().take(locale);
74
75 UErrorCode setTextStatus = U_ZERO_ERROR;
76 ubrk_setText(iterator, string, length, &setTextStatus);
77 if (U_FAILURE(setTextStatus)) {
78 LOG_ERROR("ubrk_setText failed with status %d", setTextStatus);
79 return 0;
80 }
(gdb) b 75
Breakpoint 1 at 0xf8a7440: file Source/WebCore/platform/text/TextBreakIteratorICU.cpp, line 75.
Any ideas what might be wrong here? Maybe some confusion about wide vs not-wide
character representation (I've seen this one a lot, especially on PowerPC systems)?
Any clues where to look next?
I did note that 'locale' into this function is also NULL.
Should I file a bug?
Note: I tried this with the stock Poky master 9d1db6cc928199f8ac4960e8d4648563ef141427
building for qemuppc and running web2 via ssh -X (since qemu doesn't support graphics?)
The failure is the same, so this is not something special in my setup.
Note 2: it's difficult to get this to fail when running in qemu since it only fails
when it's loading and rendering the www.google.co.uk default page. I couldn't figure
out how to get my qemu system to be able to access that page over the net, but I ran
the same Yocto filesystem on my hardware (this is not a hardware bug) with the same
failure. Maybe someone smarter than me can show me how to get qemu to actually access
the internet (when the machine that's running qemu is inside a NAT'd zone)?
Thanks for any help/ideas
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-09-30 20:15 web2 on PPC Gary Thomas
@ 2011-10-03 14:59 ` Gary Thomas
2011-10-03 20:14 ` Khem Raj
2011-10-03 15:50 ` Holger Hans Peter Freyther
1 sibling, 1 reply; 12+ messages in thread
From: Gary Thomas @ 2011-10-03 14:59 UTC (permalink / raw)
To: Poky Project
On 2011-09-30 14:15, Gary Thomas wrote:
> I'm trying to run the web-webkit browser on my PowerPC system (built using Poky).
> I've built this on ARM and it runs great, but on PowerPC it fails almost immediately.
> Following into the failure with GDB, it looks like it's trying to build up a string
> using a [possibly] wide character iterator. It fails on line 76 of the code below,
> going through it by hand shows that 'iterator' is NULL.
>
> (gdb) dir /local/logopak8347tbga_new/tmp/work/ppc603e-amltd-linux/webkit-gtk-1.5.1+svnr90727-r0
> (gdb) l
> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string, int length, const AtomicString& locale)
> 72 {
> 73 UBreakIterator* iterator = LineBreakIteratorPool::sharedPool().take(locale);
> 74
> 75 UErrorCode setTextStatus = U_ZERO_ERROR;
> 76 ubrk_setText(iterator, string, length, &setTextStatus);
> 77 if (U_FAILURE(setTextStatus)) {
> 78 LOG_ERROR("ubrk_setText failed with status %d", setTextStatus);
> 79 return 0;
> 80 }
> (gdb) b 75
> Breakpoint 1 at 0xf8a7440: file Source/WebCore/platform/text/TextBreakIteratorICU.cpp, line 75.
>
> Any ideas what might be wrong here? Maybe some confusion about wide vs not-wide
> character representation (I've seen this one a lot, especially on PowerPC systems)?
> Any clues where to look next?
> I did note that 'locale' into this function is also NULL.
>
> Should I file a bug?
>
> Note: I tried this with the stock Poky master 9d1db6cc928199f8ac4960e8d4648563ef141427
> building for qemuppc and running web2 via ssh -X (since qemu doesn't support graphics?)
> The failure is the same, so this is not something special in my setup.
>
> Note 2: it's difficult to get this to fail when running in qemu since it only fails
> when it's loading and rendering the www.google.co.uk default page. I couldn't figure
> out how to get my qemu system to be able to access that page over the net, but I ran
> the same Yocto filesystem on my hardware (this is not a hardware bug) with the same
> failure. Maybe someone smarter than me can show me how to get qemu to actually access
> the internet (when the machine that's running qemu is inside a NAT'd zone)?
>
> Thanks for any help/ideas
>
Filed as http://bugzilla.pokylinux.org/show_bug.cgi?id=1570
Still looking for ideas on where to look, how to debug this.
Thanks
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-09-30 20:15 web2 on PPC Gary Thomas
2011-10-03 14:59 ` Gary Thomas
@ 2011-10-03 15:50 ` Holger Hans Peter Freyther
2011-10-03 16:04 ` Gary Thomas
1 sibling, 1 reply; 12+ messages in thread
From: Holger Hans Peter Freyther @ 2011-10-03 15:50 UTC (permalink / raw)
To: poky
On 09/30/2011 10:15 PM, Gary Thomas wrote:
> (gdb) l
> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string, int
> length, const AtomicString& locale)
what is locale? is ICU missing some data files that could/should be installed
(strace or such). The AtomicString class has a way to get the String which has
a way to convert/encode to UTF8 which has a way to get the data that can be
printed with printf. :)
holger
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-10-03 15:50 ` Holger Hans Peter Freyther
@ 2011-10-03 16:04 ` Gary Thomas
2011-10-03 17:36 ` Holger Hans Peter Freyther
0 siblings, 1 reply; 12+ messages in thread
From: Gary Thomas @ 2011-10-03 16:04 UTC (permalink / raw)
To: Holger Hans Peter Freyther; +Cc: poky
On 2011-10-03 09:50, Holger Hans Peter Freyther wrote:
> On 09/30/2011 10:15 PM, Gary Thomas wrote:
>
>> (gdb) l
>> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string, int
>> length, const AtomicString& locale)
>
> what is locale? is ICU missing some data files that could/should be installed
> (strace or such). The AtomicString class has a way to get the String which has
> a way to convert/encode to UTF8 which has a way to get the data that can be
> printed with printf. :)
As mentioned, the 'locale' variable is NULL
The real question is why this program works just fine on ARM, but fails on PPC.
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-10-03 16:04 ` Gary Thomas
@ 2011-10-03 17:36 ` Holger Hans Peter Freyther
0 siblings, 0 replies; 12+ messages in thread
From: Holger Hans Peter Freyther @ 2011-10-03 17:36 UTC (permalink / raw)
To: poky
On 10/03/2011 06:04 PM, Gary Thomas wrote:
> On 2011-10-03 09:50, Holger Hans Peter Freyther wrote:
>
> As mentioned, the 'locale' variable is NULL
It can not be NULL (as in pointer), it might be that it is an empty atomic
string. I am not expert on PPC, the guesses are:
1.) alignment rules... we might do unaligned access that manifests weirdly here?
2.) Look into LineBreakIteratorPool::sharedPool() and check if there is
something obvious...
3.) Look if ICU is compiled differently for ARM/PPC?
cheers
holger
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-10-03 14:59 ` Gary Thomas
@ 2011-10-03 20:14 ` Khem Raj
2011-10-04 13:14 ` Gary Thomas
0 siblings, 1 reply; 12+ messages in thread
From: Khem Raj @ 2011-10-03 20:14 UTC (permalink / raw)
To: poky
On 10/3/2011 7:59 AM, Gary Thomas wrote:
> On 2011-09-30 14:15, Gary Thomas wrote:
>> I'm trying to run the web-webkit browser on my PowerPC system (built
>> using Poky).
>> I've built this on ARM and it runs great, but on PowerPC it fails
>> almost immediately.
>> Following into the failure with GDB, it looks like it's trying to
>> build up a string
>> using a [possibly] wide character iterator. It fails on line 76 of the
>> code below,
>> going through it by hand shows that 'iterator' is NULL.
>>
>> (gdb) dir
>> /local/logopak8347tbga_new/tmp/work/ppc603e-amltd-linux/webkit-gtk-1.5.1+svnr90727-r0
>>
>> (gdb) l
>> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string,
>> int length, const AtomicString& locale)
>> 72 {
>> 73 UBreakIterator* iterator =
>> LineBreakIteratorPool::sharedPool().take(locale);
>> 74
>> 75 UErrorCode setTextStatus = U_ZERO_ERROR;
>> 76 ubrk_setText(iterator, string, length, &setTextStatus);
>> 77 if (U_FAILURE(setTextStatus)) {
>> 78 LOG_ERROR("ubrk_setText failed with status %d", setTextStatus);
>> 79 return 0;
>> 80 }
>> (gdb) b 75
>> Breakpoint 1 at 0xf8a7440: file
>> Source/WebCore/platform/text/TextBreakIteratorICU.cpp, line 75.
>>
>> Any ideas what might be wrong here? Maybe some confusion about wide vs
>> not-wide
>> character representation (I've seen this one a lot, especially on
>> PowerPC systems)?
>> Any clues where to look next?
>> I did note that 'locale' into this function is also NULL.
>>
>> Should I file a bug?
>>
>> Note: I tried this with the stock Poky master
>> 9d1db6cc928199f8ac4960e8d4648563ef141427
>> building for qemuppc and running web2 via ssh -X (since qemu doesn't
>> support graphics?)
>> The failure is the same, so this is not something special in my setup.
>>
>> Note 2: it's difficult to get this to fail when running in qemu since
>> it only fails
>> when it's loading and rendering the www.google.co.uk default page. I
>> couldn't figure
>> out how to get my qemu system to be able to access that page over the
>> net, but I ran
>> the same Yocto filesystem on my hardware (this is not a hardware bug)
>> with the same
>> failure. Maybe someone smarter than me can show me how to get qemu to
>> actually access
>> the internet (when the machine that's running qemu is inside a NAT'd
>> zone)?
>>
>> Thanks for any help/ideas
>>
>
> Filed as http://bugzilla.pokylinux.org/show_bug.cgi?id=1570
>
> Still looking for ideas on where to look, how to debug this.
such problems can happen when autoconf variables are not cached with
right values. So look into site files. What variables to look for can be
taken from config.log of the package.
>
> Thanks
>
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-10-03 20:14 ` Khem Raj
@ 2011-10-04 13:14 ` Gary Thomas
2011-10-04 16:11 ` Khem Raj
0 siblings, 1 reply; 12+ messages in thread
From: Gary Thomas @ 2011-10-04 13:14 UTC (permalink / raw)
To: Khem Raj; +Cc: poky
On 2011-10-03 14:14, Khem Raj wrote:
> On 10/3/2011 7:59 AM, Gary Thomas wrote:
>> On 2011-09-30 14:15, Gary Thomas wrote:
>>> I'm trying to run the web-webkit browser on my PowerPC system (built
>>> using Poky).
>>> I've built this on ARM and it runs great, but on PowerPC it fails
>>> almost immediately.
>>> Following into the failure with GDB, it looks like it's trying to
>>> build up a string
>>> using a [possibly] wide character iterator. It fails on line 76 of the
>>> code below,
>>> going through it by hand shows that 'iterator' is NULL.
>>>
>>> (gdb) dir
>>> /local/logopak8347tbga_new/tmp/work/ppc603e-amltd-linux/webkit-gtk-1.5.1+svnr90727-r0
>>>
>>> (gdb) l
>>> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string,
>>> int length, const AtomicString& locale)
>>> 72 {
>>> 73 UBreakIterator* iterator =
>>> LineBreakIteratorPool::sharedPool().take(locale);
>>> 74
>>> 75 UErrorCode setTextStatus = U_ZERO_ERROR;
>>> 76 ubrk_setText(iterator, string, length, &setTextStatus);
>>> 77 if (U_FAILURE(setTextStatus)) {
>>> 78 LOG_ERROR("ubrk_setText failed with status %d", setTextStatus);
>>> 79 return 0;
>>> 80 }
>>> (gdb) b 75
>>> Breakpoint 1 at 0xf8a7440: file
>>> Source/WebCore/platform/text/TextBreakIteratorICU.cpp, line 75.
>>>
>>> Any ideas what might be wrong here? Maybe some confusion about wide vs
>>> not-wide
>>> character representation (I've seen this one a lot, especially on
>>> PowerPC systems)?
>>> Any clues where to look next?
>>> I did note that 'locale' into this function is also NULL.
>>>
>>> Should I file a bug?
>>>
>>> Note: I tried this with the stock Poky master
>>> 9d1db6cc928199f8ac4960e8d4648563ef141427
>>> building for qemuppc and running web2 via ssh -X (since qemu doesn't
>>> support graphics?)
>>> The failure is the same, so this is not something special in my setup.
>>>
>>> Note 2: it's difficult to get this to fail when running in qemu since
>>> it only fails
>>> when it's loading and rendering the www.google.co.uk default page. I
>>> couldn't figure
>>> out how to get my qemu system to be able to access that page over the
>>> net, but I ran
>>> the same Yocto filesystem on my hardware (this is not a hardware bug)
>>> with the same
>>> failure. Maybe someone smarter than me can show me how to get qemu to
>>> actually access
>>> the internet (when the machine that's running qemu is inside a NAT'd
>>> zone)?
>>>
>>> Thanks for any help/ideas
>>>
>>
>> Filed as http://bugzilla.pokylinux.org/show_bug.cgi?id=1570
>>
>> Still looking for ideas on where to look, how to debug this.
>
> such problems can happen when autoconf variables are not cached with right values. So look into site files. What variables to look for can be
> taken from config.log of the package.
>
It turns out the problem is that the ICU library does not work
properly (at all!) when the host and target systems have different
endianness. If I install ICU libraries which were built on a
native PowerPC system, the 'web2' program works.
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-10-04 13:14 ` Gary Thomas
@ 2011-10-04 16:11 ` Khem Raj
2011-10-04 16:19 ` Gary Thomas
0 siblings, 1 reply; 12+ messages in thread
From: Khem Raj @ 2011-10-04 16:11 UTC (permalink / raw)
To: Gary Thomas; +Cc: poky
On 10/4/2011 6:14 AM, Gary Thomas wrote:
> On 2011-10-03 14:14, Khem Raj wrote:
>> On 10/3/2011 7:59 AM, Gary Thomas wrote:
>>> On 2011-09-30 14:15, Gary Thomas wrote:
>>>> I'm trying to run the web-webkit browser on my PowerPC system (built
>>>> using Poky).
>>>> I've built this on ARM and it runs great, but on PowerPC it fails
>>>> almost immediately.
>>>> Following into the failure with GDB, it looks like it's trying to
>>>> build up a string
>>>> using a [possibly] wide character iterator. It fails on line 76 of the
>>>> code below,
>>>> going through it by hand shows that 'iterator' is NULL.
>>>>
>>>> (gdb) dir
>>>> /local/logopak8347tbga_new/tmp/work/ppc603e-amltd-linux/webkit-gtk-1.5.1+svnr90727-r0
>>>>
>>>>
>>>> (gdb) l
>>>> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string,
>>>> int length, const AtomicString& locale)
>>>> 72 {
>>>> 73 UBreakIterator* iterator =
>>>> LineBreakIteratorPool::sharedPool().take(locale);
>>>> 74
>>>> 75 UErrorCode setTextStatus = U_ZERO_ERROR;
>>>> 76 ubrk_setText(iterator, string, length, &setTextStatus);
>>>> 77 if (U_FAILURE(setTextStatus)) {
>>>> 78 LOG_ERROR("ubrk_setText failed with status %d", setTextStatus);
>>>> 79 return 0;
>>>> 80 }
>>>> (gdb) b 75
>>>> Breakpoint 1 at 0xf8a7440: file
>>>> Source/WebCore/platform/text/TextBreakIteratorICU.cpp, line 75.
>>>>
>>>> Any ideas what might be wrong here? Maybe some confusion about wide vs
>>>> not-wide
>>>> character representation (I've seen this one a lot, especially on
>>>> PowerPC systems)?
>>>> Any clues where to look next?
>>>> I did note that 'locale' into this function is also NULL.
>>>>
>>>> Should I file a bug?
>>>>
>>>> Note: I tried this with the stock Poky master
>>>> 9d1db6cc928199f8ac4960e8d4648563ef141427
>>>> building for qemuppc and running web2 via ssh -X (since qemu doesn't
>>>> support graphics?)
>>>> The failure is the same, so this is not something special in my setup.
>>>>
>>>> Note 2: it's difficult to get this to fail when running in qemu since
>>>> it only fails
>>>> when it's loading and rendering the www.google.co.uk default page. I
>>>> couldn't figure
>>>> out how to get my qemu system to be able to access that page over the
>>>> net, but I ran
>>>> the same Yocto filesystem on my hardware (this is not a hardware bug)
>>>> with the same
>>>> failure. Maybe someone smarter than me can show me how to get qemu to
>>>> actually access
>>>> the internet (when the machine that's running qemu is inside a NAT'd
>>>> zone)?
>>>>
>>>> Thanks for any help/ideas
>>>>
>>>
>>> Filed as http://bugzilla.pokylinux.org/show_bug.cgi?id=1570
>>>
>>> Still looking for ideas on where to look, how to debug this.
>>
>> such problems can happen when autoconf variables are not cached with
>> right values. So look into site files. What variables to look for can be
>> taken from config.log of the package.
>>
>
> It turns out the problem is that the ICU library does not work
> properly (at all!) when the host and target systems have different
> endianness. If I install ICU libraries which were built on a
> native PowerPC system, the 'web2' program works.
>
compare the configure outputs of icu between cross and native ppc build
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-10-04 16:11 ` Khem Raj
@ 2011-10-04 16:19 ` Gary Thomas
2011-10-05 13:44 ` Richard Purdie
0 siblings, 1 reply; 12+ messages in thread
From: Gary Thomas @ 2011-10-04 16:19 UTC (permalink / raw)
To: Khem Raj; +Cc: poky
On 2011-10-04 10:11, Khem Raj wrote:
> On 10/4/2011 6:14 AM, Gary Thomas wrote:
>> On 2011-10-03 14:14, Khem Raj wrote:
>>> On 10/3/2011 7:59 AM, Gary Thomas wrote:
>>>> On 2011-09-30 14:15, Gary Thomas wrote:
>>>>> I'm trying to run the web-webkit browser on my PowerPC system (built
>>>>> using Poky).
>>>>> I've built this on ARM and it runs great, but on PowerPC it fails
>>>>> almost immediately.
>>>>> Following into the failure with GDB, it looks like it's trying to
>>>>> build up a string
>>>>> using a [possibly] wide character iterator. It fails on line 76 of the
>>>>> code below,
>>>>> going through it by hand shows that 'iterator' is NULL.
>>>>>
>>>>> (gdb) dir
>>>>> /local/logopak8347tbga_new/tmp/work/ppc603e-amltd-linux/webkit-gtk-1.5.1+svnr90727-r0
>>>>>
>>>>>
>>>>> (gdb) l
>>>>> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string,
>>>>> int length, const AtomicString& locale)
>>>>> 72 {
>>>>> 73 UBreakIterator* iterator =
>>>>> LineBreakIteratorPool::sharedPool().take(locale);
>>>>> 74
>>>>> 75 UErrorCode setTextStatus = U_ZERO_ERROR;
>>>>> 76 ubrk_setText(iterator, string, length, &setTextStatus);
>>>>> 77 if (U_FAILURE(setTextStatus)) {
>>>>> 78 LOG_ERROR("ubrk_setText failed with status %d", setTextStatus);
>>>>> 79 return 0;
>>>>> 80 }
>>>>> (gdb) b 75
>>>>> Breakpoint 1 at 0xf8a7440: file
>>>>> Source/WebCore/platform/text/TextBreakIteratorICU.cpp, line 75.
>>>>>
>>>>> Any ideas what might be wrong here? Maybe some confusion about wide vs
>>>>> not-wide
>>>>> character representation (I've seen this one a lot, especially on
>>>>> PowerPC systems)?
>>>>> Any clues where to look next?
>>>>> I did note that 'locale' into this function is also NULL.
>>>>>
>>>>> Should I file a bug?
>>>>>
>>>>> Note: I tried this with the stock Poky master
>>>>> 9d1db6cc928199f8ac4960e8d4648563ef141427
>>>>> building for qemuppc and running web2 via ssh -X (since qemu doesn't
>>>>> support graphics?)
>>>>> The failure is the same, so this is not something special in my setup.
>>>>>
>>>>> Note 2: it's difficult to get this to fail when running in qemu since
>>>>> it only fails
>>>>> when it's loading and rendering the www.google.co.uk default page. I
>>>>> couldn't figure
>>>>> out how to get my qemu system to be able to access that page over the
>>>>> net, but I ran
>>>>> the same Yocto filesystem on my hardware (this is not a hardware bug)
>>>>> with the same
>>>>> failure. Maybe someone smarter than me can show me how to get qemu to
>>>>> actually access
>>>>> the internet (when the machine that's running qemu is inside a NAT'd
>>>>> zone)?
>>>>>
>>>>> Thanks for any help/ideas
>>>>>
>>>>
>>>> Filed as http://bugzilla.pokylinux.org/show_bug.cgi?id=1570
>>>>
>>>> Still looking for ideas on where to look, how to debug this.
>>>
>>> such problems can happen when autoconf variables are not cached with
>>> right values. So look into site files. What variables to look for can be
>>> taken from config.log of the package.
>>>
>>
>> It turns out the problem is that the ICU library does not work
>> properly (at all!) when the host and target systems have different
>> endianness. If I install ICU libraries which were built on a
>> native PowerPC system, the 'web2' program works.
>>
>
> compare the configure outputs of icu between cross and native ppc build
I have - they are totally broken in the cross-compile setup.
The ICU library has a tool which is used to covert their internal
data base to the proper endianness. However, it only works properly
when converting _to_ the endianness of the machine it runs on. It will
not convert a little endian data base to a big endian version when the
tool is run on a little endian machine. I tried to get the ICU folks
to fix this more than a year ago, but they weren't interested in this
case.
I think I have a solution, albeit a bit crude. The ICU library builder
can take a properly ordered data base as input and not do any of this
mucking around. In fact, the library ships with the little endian version
which is used untouched on little endian targets. I can produce the big
endian version and just provide it to the recipe. One problem with this
is that it's HUGE - 18MB, so I'm not quite sure where to put it.
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-10-04 16:19 ` Gary Thomas
@ 2011-10-05 13:44 ` Richard Purdie
2011-10-05 13:53 ` Gary Thomas
0 siblings, 1 reply; 12+ messages in thread
From: Richard Purdie @ 2011-10-05 13:44 UTC (permalink / raw)
To: Gary Thomas; +Cc: poky
On Tue, 2011-10-04 at 10:19 -0600, Gary Thomas wrote:
> On 2011-10-04 10:11, Khem Raj wrote:
> > On 10/4/2011 6:14 AM, Gary Thomas wrote:
> >> On 2011-10-03 14:14, Khem Raj wrote:
> >>> On 10/3/2011 7:59 AM, Gary Thomas wrote:
> >>>> On 2011-09-30 14:15, Gary Thomas wrote:
> >>>>> I'm trying to run the web-webkit browser on my PowerPC system (built
> >>>>> using Poky).
> >>>>> I've built this on ARM and it runs great, but on PowerPC it fails
> >>>>> almost immediately.
> >>>>> Following into the failure with GDB, it looks like it's trying to
> >>>>> build up a string
> >>>>> using a [possibly] wide character iterator. It fails on line 76 of the
> >>>>> code below,
> >>>>> going through it by hand shows that 'iterator' is NULL.
> >>>>>
> >>>>> (gdb) dir
> >>>>> /local/logopak8347tbga_new/tmp/work/ppc603e-amltd-linux/webkit-gtk-1.5.1+svnr90727-r0
> >>>>>
> >>>>>
> >>>>> (gdb) l
> >>>>> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string,
> >>>>> int length, const AtomicString& locale)
> >>>>> 72 {
> >>>>> 73 UBreakIterator* iterator =
> >>>>> LineBreakIteratorPool::sharedPool().take(locale);
> >>>>> 74
> >>>>> 75 UErrorCode setTextStatus = U_ZERO_ERROR;
> >>>>> 76 ubrk_setText(iterator, string, length, &setTextStatus);
> >>>>> 77 if (U_FAILURE(setTextStatus)) {
> >>>>> 78 LOG_ERROR("ubrk_setText failed with status %d", setTextStatus);
> >>>>> 79 return 0;
> >>>>> 80 }
> >>>>> (gdb) b 75
> >>>>> Breakpoint 1 at 0xf8a7440: file
> >>>>> Source/WebCore/platform/text/TextBreakIteratorICU.cpp, line 75.
> >>>>>
> >>>>> Any ideas what might be wrong here? Maybe some confusion about wide vs
> >>>>> not-wide
> >>>>> character representation (I've seen this one a lot, especially on
> >>>>> PowerPC systems)?
> >>>>> Any clues where to look next?
> >>>>> I did note that 'locale' into this function is also NULL.
> >>>>>
> >>>>> Should I file a bug?
> >>>>>
> >>>>> Note: I tried this with the stock Poky master
> >>>>> 9d1db6cc928199f8ac4960e8d4648563ef141427
> >>>>> building for qemuppc and running web2 via ssh -X (since qemu doesn't
> >>>>> support graphics?)
> >>>>> The failure is the same, so this is not something special in my setup.
> >>>>>
> >>>>> Note 2: it's difficult to get this to fail when running in qemu since
> >>>>> it only fails
> >>>>> when it's loading and rendering the www.google.co.uk default page. I
> >>>>> couldn't figure
> >>>>> out how to get my qemu system to be able to access that page over the
> >>>>> net, but I ran
> >>>>> the same Yocto filesystem on my hardware (this is not a hardware bug)
> >>>>> with the same
> >>>>> failure. Maybe someone smarter than me can show me how to get qemu to
> >>>>> actually access
> >>>>> the internet (when the machine that's running qemu is inside a NAT'd
> >>>>> zone)?
> >>>>>
> >>>>> Thanks for any help/ideas
> >>>>>
> >>>>
> >>>> Filed as http://bugzilla.pokylinux.org/show_bug.cgi?id=1570
> >>>>
> >>>> Still looking for ideas on where to look, how to debug this.
> >>>
> >>> such problems can happen when autoconf variables are not cached with
> >>> right values. So look into site files. What variables to look for can be
> >>> taken from config.log of the package.
> >>>
> >>
> >> It turns out the problem is that the ICU library does not work
> >> properly (at all!) when the host and target systems have different
> >> endianness. If I install ICU libraries which were built on a
> >> native PowerPC system, the 'web2' program works.
> >>
> >
> > compare the configure outputs of icu between cross and native ppc build
>
> I have - they are totally broken in the cross-compile setup.
>
> The ICU library has a tool which is used to covert their internal
> data base to the proper endianness. However, it only works properly
> when converting _to_ the endianness of the machine it runs on. It will
> not convert a little endian data base to a big endian version when the
> tool is run on a little endian machine. I tried to get the ICU folks
> to fix this more than a year ago, but they weren't interested in this
> case.
Is there much needed to make this tool work across different endians? It
depends what its doing I guess...
> I think I have a solution, albeit a bit crude. The ICU library builder
> can take a properly ordered data base as input and not do any of this
> mucking around. In fact, the library ships with the little endian version
> which is used untouched on little endian targets. I can produce the big
> endian version and just provide it to the recipe. One problem with this
> is that it's HUGE - 18MB, so I'm not quite sure where to put it.
Is that compressed?
I'd be prepared to host that on the Yocto web server so that we can fix
the big endian builds for now although its not really a long term
solution...
Cheers,
Richard
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-10-05 13:44 ` Richard Purdie
@ 2011-10-05 13:53 ` Gary Thomas
2011-10-05 15:10 ` Gary Thomas
0 siblings, 1 reply; 12+ messages in thread
From: Gary Thomas @ 2011-10-05 13:53 UTC (permalink / raw)
To: Richard Purdie; +Cc: poky
On 2011-10-05 07:44, Richard Purdie wrote:
> On Tue, 2011-10-04 at 10:19 -0600, Gary Thomas wrote:
>> On 2011-10-04 10:11, Khem Raj wrote:
>>> On 10/4/2011 6:14 AM, Gary Thomas wrote:
>>>> On 2011-10-03 14:14, Khem Raj wrote:
>>>>> On 10/3/2011 7:59 AM, Gary Thomas wrote:
>>>>>> On 2011-09-30 14:15, Gary Thomas wrote:
>>>>>>> I'm trying to run the web-webkit browser on my PowerPC system (built
>>>>>>> using Poky).
>>>>>>> I've built this on ARM and it runs great, but on PowerPC it fails
>>>>>>> almost immediately.
>>>>>>> Following into the failure with GDB, it looks like it's trying to
>>>>>>> build up a string
>>>>>>> using a [possibly] wide character iterator. It fails on line 76 of the
>>>>>>> code below,
>>>>>>> going through it by hand shows that 'iterator' is NULL.
>>>>>>>
>>>>>>> (gdb) dir
>>>>>>> /local/logopak8347tbga_new/tmp/work/ppc603e-amltd-linux/webkit-gtk-1.5.1+svnr90727-r0
>>>>>>>
>>>>>>>
>>>>>>> (gdb) l
>>>>>>> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string,
>>>>>>> int length, const AtomicString& locale)
>>>>>>> 72 {
>>>>>>> 73 UBreakIterator* iterator =
>>>>>>> LineBreakIteratorPool::sharedPool().take(locale);
>>>>>>> 74
>>>>>>> 75 UErrorCode setTextStatus = U_ZERO_ERROR;
>>>>>>> 76 ubrk_setText(iterator, string, length,&setTextStatus);
>>>>>>> 77 if (U_FAILURE(setTextStatus)) {
>>>>>>> 78 LOG_ERROR("ubrk_setText failed with status %d", setTextStatus);
>>>>>>> 79 return 0;
>>>>>>> 80 }
>>>>>>> (gdb) b 75
>>>>>>> Breakpoint 1 at 0xf8a7440: file
>>>>>>> Source/WebCore/platform/text/TextBreakIteratorICU.cpp, line 75.
>>>>>>>
>>>>>>> Any ideas what might be wrong here? Maybe some confusion about wide vs
>>>>>>> not-wide
>>>>>>> character representation (I've seen this one a lot, especially on
>>>>>>> PowerPC systems)?
>>>>>>> Any clues where to look next?
>>>>>>> I did note that 'locale' into this function is also NULL.
>>>>>>>
>>>>>>> Should I file a bug?
>>>>>>>
>>>>>>> Note: I tried this with the stock Poky master
>>>>>>> 9d1db6cc928199f8ac4960e8d4648563ef141427
>>>>>>> building for qemuppc and running web2 via ssh -X (since qemu doesn't
>>>>>>> support graphics?)
>>>>>>> The failure is the same, so this is not something special in my setup.
>>>>>>>
>>>>>>> Note 2: it's difficult to get this to fail when running in qemu since
>>>>>>> it only fails
>>>>>>> when it's loading and rendering the www.google.co.uk default page. I
>>>>>>> couldn't figure
>>>>>>> out how to get my qemu system to be able to access that page over the
>>>>>>> net, but I ran
>>>>>>> the same Yocto filesystem on my hardware (this is not a hardware bug)
>>>>>>> with the same
>>>>>>> failure. Maybe someone smarter than me can show me how to get qemu to
>>>>>>> actually access
>>>>>>> the internet (when the machine that's running qemu is inside a NAT'd
>>>>>>> zone)?
>>>>>>>
>>>>>>> Thanks for any help/ideas
>>>>>>>
>>>>>>
>>>>>> Filed as http://bugzilla.pokylinux.org/show_bug.cgi?id=1570
>>>>>>
>>>>>> Still looking for ideas on where to look, how to debug this.
>>>>>
>>>>> such problems can happen when autoconf variables are not cached with
>>>>> right values. So look into site files. What variables to look for can be
>>>>> taken from config.log of the package.
>>>>>
>>>>
>>>> It turns out the problem is that the ICU library does not work
>>>> properly (at all!) when the host and target systems have different
>>>> endianness. If I install ICU libraries which were built on a
>>>> native PowerPC system, the 'web2' program works.
>>>>
>>>
>>> compare the configure outputs of icu between cross and native ppc build
>>
>> I have - they are totally broken in the cross-compile setup.
>>
>> The ICU library has a tool which is used to covert their internal
>> data base to the proper endianness. However, it only works properly
>> when converting _to_ the endianness of the machine it runs on. It will
>> not convert a little endian data base to a big endian version when the
>> tool is run on a little endian machine. I tried to get the ICU folks
>> to fix this more than a year ago, but they weren't interested in this
>> case.
>
> Is there much needed to make this tool work across different endians? It
> depends what its doing I guess...
It's a horrible mess :-( I've spent a number of days trying to get this
thing working with no luck. As I said, I got little joy from the upstream
folks - they don't seem to be concerned that this doesn't work properly.
Maybe if they were contacted from someone with more clout (Intel?), they'd
be more interested.
>
>> I think I have a solution, albeit a bit crude. The ICU library builder
>> can take a properly ordered data base as input and not do any of this
>> mucking around. In fact, the library ships with the little endian version
>> which is used untouched on little endian targets. I can produce the big
>> endian version and just provide it to the recipe. One problem with this
>> is that it's HUGE - 18MB, so I'm not quite sure where to put it.
>
> Is that compressed?
Compressed it's less than 7MB.
>
> I'd be prepared to host that on the Yocto web server so that we can fix
> the big endian builds for now although its not really a long term
> solution...
The only "solution" I've come up with so far is to simply replace one
of the libraries that gets built with one that works. There doesn't
seem to be any way to get the existing build system to create the library
properly. I'll package up what I have and send a pointer for review.
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: web2 on PPC
2011-10-05 13:53 ` Gary Thomas
@ 2011-10-05 15:10 ` Gary Thomas
0 siblings, 0 replies; 12+ messages in thread
From: Gary Thomas @ 2011-10-05 15:10 UTC (permalink / raw)
To: Richard Purdie; +Cc: poky
On 2011-10-05 07:53, Gary Thomas wrote:
> On 2011-10-05 07:44, Richard Purdie wrote:
>> On Tue, 2011-10-04 at 10:19 -0600, Gary Thomas wrote:
>>> On 2011-10-04 10:11, Khem Raj wrote:
>>>> On 10/4/2011 6:14 AM, Gary Thomas wrote:
>>>>> On 2011-10-03 14:14, Khem Raj wrote:
>>>>>> On 10/3/2011 7:59 AM, Gary Thomas wrote:
>>>>>>> On 2011-09-30 14:15, Gary Thomas wrote:
>>>>>>>> I'm trying to run the web-webkit browser on my PowerPC system (built
>>>>>>>> using Poky).
>>>>>>>> I've built this on ARM and it runs great, but on PowerPC it fails
>>>>>>>> almost immediately.
>>>>>>>> Following into the failure with GDB, it looks like it's trying to
>>>>>>>> build up a string
>>>>>>>> using a [possibly] wide character iterator. It fails on line 76 of the
>>>>>>>> code below,
>>>>>>>> going through it by hand shows that 'iterator' is NULL.
>>>>>>>>
>>>>>>>> (gdb) dir
>>>>>>>> /local/logopak8347tbga_new/tmp/work/ppc603e-amltd-linux/webkit-gtk-1.5.1+svnr90727-r0
>>>>>>>>
>>>>>>>>
>>>>>>>> (gdb) l
>>>>>>>> 71 TextBreakIterator* acquireLineBreakIterator(const UChar* string,
>>>>>>>> int length, const AtomicString& locale)
>>>>>>>> 72 {
>>>>>>>> 73 UBreakIterator* iterator =
>>>>>>>> LineBreakIteratorPool::sharedPool().take(locale);
>>>>>>>> 74
>>>>>>>> 75 UErrorCode setTextStatus = U_ZERO_ERROR;
>>>>>>>> 76 ubrk_setText(iterator, string, length,&setTextStatus);
>>>>>>>> 77 if (U_FAILURE(setTextStatus)) {
>>>>>>>> 78 LOG_ERROR("ubrk_setText failed with status %d", setTextStatus);
>>>>>>>> 79 return 0;
>>>>>>>> 80 }
>>>>>>>> (gdb) b 75
>>>>>>>> Breakpoint 1 at 0xf8a7440: file
>>>>>>>> Source/WebCore/platform/text/TextBreakIteratorICU.cpp, line 75.
>>>>>>>>
>>>>>>>> Any ideas what might be wrong here? Maybe some confusion about wide vs
>>>>>>>> not-wide
>>>>>>>> character representation (I've seen this one a lot, especially on
>>>>>>>> PowerPC systems)?
>>>>>>>> Any clues where to look next?
>>>>>>>> I did note that 'locale' into this function is also NULL.
>>>>>>>>
>>>>>>>> Should I file a bug?
>>>>>>>>
>>>>>>>> Note: I tried this with the stock Poky master
>>>>>>>> 9d1db6cc928199f8ac4960e8d4648563ef141427
>>>>>>>> building for qemuppc and running web2 via ssh -X (since qemu doesn't
>>>>>>>> support graphics?)
>>>>>>>> The failure is the same, so this is not something special in my setup.
>>>>>>>>
>>>>>>>> Note 2: it's difficult to get this to fail when running in qemu since
>>>>>>>> it only fails
>>>>>>>> when it's loading and rendering the www.google.co.uk default page. I
>>>>>>>> couldn't figure
>>>>>>>> out how to get my qemu system to be able to access that page over the
>>>>>>>> net, but I ran
>>>>>>>> the same Yocto filesystem on my hardware (this is not a hardware bug)
>>>>>>>> with the same
>>>>>>>> failure. Maybe someone smarter than me can show me how to get qemu to
>>>>>>>> actually access
>>>>>>>> the internet (when the machine that's running qemu is inside a NAT'd
>>>>>>>> zone)?
>>>>>>>>
>>>>>>>> Thanks for any help/ideas
>>>>>>>>
>>>>>>>
>>>>>>> Filed as http://bugzilla.pokylinux.org/show_bug.cgi?id=1570
>>>>>>>
>>>>>>> Still looking for ideas on where to look, how to debug this.
>>>>>>
>>>>>> such problems can happen when autoconf variables are not cached with
>>>>>> right values. So look into site files. What variables to look for can be
>>>>>> taken from config.log of the package.
>>>>>>
>>>>>
>>>>> It turns out the problem is that the ICU library does not work
>>>>> properly (at all!) when the host and target systems have different
>>>>> endianness. If I install ICU libraries which were built on a
>>>>> native PowerPC system, the 'web2' program works.
>>>>>
>>>>
>>>> compare the configure outputs of icu between cross and native ppc build
>>>
>>> I have - they are totally broken in the cross-compile setup.
>>>
>>> The ICU library has a tool which is used to covert their internal
>>> data base to the proper endianness. However, it only works properly
>>> when converting _to_ the endianness of the machine it runs on. It will
>>> not convert a little endian data base to a big endian version when the
>>> tool is run on a little endian machine. I tried to get the ICU folks
>>> to fix this more than a year ago, but they weren't interested in this
>>> case.
>>
>> Is there much needed to make this tool work across different endians? It
>> depends what its doing I guess...
>
> It's a horrible mess :-( I've spent a number of days trying to get this
> thing working with no luck. As I said, I got little joy from the upstream
> folks - they don't seem to be concerned that this doesn't work properly.
> Maybe if they were contacted from someone with more clout (Intel?), they'd
> be more interested.
>
>>
>>> I think I have a solution, albeit a bit crude. The ICU library builder
>>> can take a properly ordered data base as input and not do any of this
>>> mucking around. In fact, the library ships with the little endian version
>>> which is used untouched on little endian targets. I can produce the big
>>> endian version and just provide it to the recipe. One problem with this
>>> is that it's HUGE - 18MB, so I'm not quite sure where to put it.
>>
>> Is that compressed?
>
> Compressed it's less than 7MB.
>
>>
>> I'd be prepared to host that on the Yocto web server so that we can fix
>> the big endian builds for now although its not really a long term
>> solution...
>
> The only "solution" I've come up with so far is to simply replace one
> of the libraries that gets built with one that works. There doesn't
> seem to be any way to get the existing build system to create the library
> properly. I'll package up what I have and send a pointer for review.
Recipe and data file (working library) attached to http://bugzilla.pokylinux.org/show_bug.cgi?id=1570
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2011-10-05 15:10 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-09-30 20:15 web2 on PPC Gary Thomas
2011-10-03 14:59 ` Gary Thomas
2011-10-03 20:14 ` Khem Raj
2011-10-04 13:14 ` Gary Thomas
2011-10-04 16:11 ` Khem Raj
2011-10-04 16:19 ` Gary Thomas
2011-10-05 13:44 ` Richard Purdie
2011-10-05 13:53 ` Gary Thomas
2011-10-05 15:10 ` Gary Thomas
2011-10-03 15:50 ` Holger Hans Peter Freyther
2011-10-03 16:04 ` Gary Thomas
2011-10-03 17:36 ` Holger Hans Peter Freyther
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.