Skip to contentSkip to conversation

AVR32 segfaults / Disablng virtual/libintl?

DISCUSSION Geoffrey Wossum 2 participants 3 messages May 16, 2008 – May 19, 2008

lore
Share & tools
lore
#0 lore raw

Hi all,

I've had some odd segfaults on my AVR32 system, mostly involving avahi (always on startup) and the occasional Xfbdev crash. I didn't bother looking into it until now, because aplay was always crashing before it even got to main(), which was making difficult to test my sound CODEC.

I found that both avahi-daemon and aplay were both crashing before they got to main(), and they both crashed due to infinite recursion calling the function _pthread_cleanup_push_defer().

Due to the crash being in a thread related function, I focused my initial attention there, but now I think the problem is related to gettext. If I hand compile aplay and keep it from linking against libintl, it doesn't crash. Haven't tried the same thing on avahi, but I suspect libintl/gettext is also the problem there since they were crashing exactly the same way.

I don't need any i18n any these types of applications. As a workaround, can I keep gettext from being built and use the libintl stubs provided by uClibc? How do I do this? PREFERRED_PROVIDER_virtual/libintl = ""? PREFERRED_PROVIDER_virtual/libintl = "uclibc"?

TIA,
---
Geoffrey

#1 lore raw
Quoted 17 lines · Geoffrey Wossum

Hi all,

I've had some odd segfaults on my AVR32 system, mostly involving avahi (always on startup) and the occasional Xfbdev crash. I didn't bother looking into it until now, because aplay was always crashing before it even got to main(), which was making difficult to test my sound CODEC.

I found that both avahi-daemon and aplay were both crashing before they got to main(), and they both crashed due to infinite recursion calling the function _pthread_cleanup_push_defer().

Due to the crash being in a thread related function, I focused my initial attention there, but now I think the problem is related to gettext. If I hand compile aplay and keep it from linking against libintl, it doesn't crash. Haven't tried the same thing on avahi, but I suspect libintl/gettext is also the problem there since they were crashing exactly the same way.

Quoted 4 lines

I don't need any i18n any these types of applications. As a workaround, can I keep gettext from being built and use the libintl stubs provided by uClibc? How do I do this? PREFERRED_PROVIDER_virtual/libintl = ""? PREFERRED_PROVIDER_virtual/libintl = "uclibc"?

That should work as long as you have wchar and intl stubs in uclibc. I would *very* much like to use the uclibc ones instead of the gettext ones, if only to get cleaner builds :)

regards,

Koen

Quoted 4 lines

TIA,
---
Geoffrey

#2 lore raw
Quoted 10 lines · Koen Kooi
Quoted 4 lines · Geoffrey Wossum

I don't need any i18n any these types of applications. As a workaround, can I keep gettext from being built and use the libintl stubs provided by uClibc? How do I do this? PREFERRED_PROVIDER_virtual/libintl = ""? PREFERRED_PROVIDER_virtual/libintl = "uclibc"?

That should work as long as you have wchar and intl stubs in uclibc. I would *very* much like to use the uclibc ones instead of the gettext ones, if only to get cleaner builds :)

Adding PREFFERRED_PROVIDER_virtual/libintl = "" makes it continue to default to pick gettext. Making the PREFERRED_PROVIDER uclibc makes it go haywire, because uClibc doesn't provide virtual/libintl, so it ends up trying to use external-toolchain and binutils-cross/gcc-cross/uClibc at the same time. OK, add patch to make uclibc provide virtual/libintl. Oops, uclibc-initial-0.9.29 fails on do_stage for the AVR32 if UCLIBC_HAS_LOCALE == y.

I can't look into this any further right, because I have to finish proving the sound out so we can spin a new board. As soon as I'm done with that, I'll continue the crusade against gettext.

---
Geoffrey