Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 595236 - mail-client/thunderbird: segfault at startup when built with gcc-6
Summary: mail-client/thunderbird: segfault at startup when built with gcc-6
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Overlays (show other bugs)
Hardware: AMD64 Linux
: Normal normal with 1 vote (vote)
Assignee: Mozilla Gentoo Team
URL:
Whiteboard:
Keywords: InOverlay
Depends on:
Blocks:
 
Reported: 2016-09-26 20:34 UTC by Francesco Turco
Modified: 2016-10-16 16:21 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (info.txt,6.26 KB, text/plain)
2016-09-26 20:35 UTC, Francesco Turco
Details
gdb log (basic version) (thunderbird.log,30.70 KB, text/plain)
2016-09-26 20:36 UTC, Francesco Turco
Details
gdb log (full version) (thunderbird-full.log,328.70 KB, text/plain)
2016-09-26 20:38 UTC, Francesco Turco
Details
gcc-6 support patch (mozilla-gcc6-support.patch,486 bytes, patch)
2016-10-09 14:14 UTC, Jory A. Pratt
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Francesco Turco 2016-09-26 20:34:47 UTC
I'm using the mail-client/thunderbird-45.3.0-r2 from the mozilla overlay. I cannot start the program because I get a segmentation fault. This doesn't happen with a clean profile. It only happens with my current working profile.

I'm going to attach some gdb logs next.
Comment 1 Francesco Turco 2016-09-26 20:35:40 UTC
Created attachment 448078 [details]
emerge --info
Comment 2 Francesco Turco 2016-09-26 20:36:27 UTC
Created attachment 448080 [details]
gdb log (basic version)
Comment 3 Francesco Turco 2016-09-26 20:38:08 UTC
Created attachment 448082 [details]
gdb log (full version)

Log with the output of the "thread apply all bt full" gdb command.
Comment 4 Francesco Turco 2016-09-26 20:42:04 UTC
In order to obtain the previous gdb logs I had to rebuild thunderbird and glibc with the following environmental variables:

CFLAGS="-march=native -O2 -ggdb -pipe"
CXXFLAGS="${CFLAGS}"
FEATURES="${FEATURES} nostrip"

----------------------

$ emerge -pv thunderbird glibc

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R   #] mail-client/thunderbird-45.3.0-r2::mozilla  USE="crypt dbus ffmpeg gstreamer jemalloc3 jit ldap minimal pulseaudio startup-notification -bindist -custom-cflags -custom-optimization -debug -gstreamer-0 -hardened -lightning -mozdom (-neon) (-selinux) (-system-cairo) -system-harfbuzz -system-icu -system-jpeg -system-libevent -system-libvpx -system-sqlite" L10N="-ar -ast -be -bg -bn-BD -br -ca -cs -cy -da -de -el -en-GB -es-AR -es-ES -et -eu -fi -fr -fy -ga -gd -gl -he -hr -hsb -hu -hy -id -is -it -ja -ko -lt -nb -nl -nn -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -sq -sr -sv -ta-LK -tr -uk -vi -zh-CN -zh-TW" 0 KiB
[ebuild   R    ] sys-libs/glibc-2.23-r2:2.2::gentoo  USE="(multilib) rpc -audit -caps -debug -gd (-hardened) -nscd -profile (-selinux) -suid -systemtap -vanilla" 0 KiB

Total: 2 packages (2 reinstalls), Size of downloads: 0 KiB

-------------------------

The only reason I'm using thunderbird from the mozilla overlay instead of the ebuild in the official tree is because the latter still cannot be built with GCC 6.2.0. See bug: https://bugs.gentoo.org/show_bug.cgi?id=592586
Comment 5 Jory A. Pratt gentoo-dev 2016-09-27 13:14:24 UTC
(In reply to Francesco Turco from comment #4)
> In order to obtain the previous gdb logs I had to rebuild thunderbird and
> glibc with the following environmental variables:
> 
> CFLAGS="-march=native -O2 -ggdb -pipe"
> CXXFLAGS="${CFLAGS}"
> FEATURES="${FEATURES} nostrip"
> 
> ----------------------
> 
> $ emerge -pv thunderbird glibc
> 
> These are the packages that would be merged, in order:
> 
> Calculating dependencies... done!
> [ebuild   R   #] mail-client/thunderbird-45.3.0-r2::mozilla  USE="crypt dbus
> ffmpeg gstreamer jemalloc3 jit ldap minimal pulseaudio startup-notification
> -bindist -custom-cflags -custom-optimization -debug -gstreamer-0 -hardened
> -lightning -mozdom (-neon) (-selinux) (-system-cairo) -system-harfbuzz
> -system-icu -system-jpeg -system-libevent -system-libvpx -system-sqlite"
> L10N="-ar -ast -be -bg -bn-BD -br -ca -cs -cy -da -de -el -en-GB -es-AR
> -es-ES -et -eu -fi -fr -fy -ga -gd -gl -he -hr -hsb -hu -hy -id -is -it -ja
> -ko -lt -nb -nl -nn -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -sq -sr
> -sv -ta-LK -tr -uk -vi -zh-CN -zh-TW" 0 KiB
> [ebuild   R    ] sys-libs/glibc-2.23-r2:2.2::gentoo  USE="(multilib) rpc
> -audit -caps -debug -gd (-hardened) -nscd -profile (-selinux) -suid
> -systemtap -vanilla" 0 KiB
> 
> Total: 2 packages (2 reinstalls), Size of downloads: 0 KiB
> 
> -------------------------
> 
> The only reason I'm using thunderbird from the mozilla overlay instead of
> the ebuild in the official tree is because the latter still cannot be built
> with GCC 6.2.0. See bug: https://bugs.gentoo.org/show_bug.cgi?id=592586

The overlay isn't correct either IMO, it needs to append proper flags so you will not see a segfault. I will try and complete it today sometime.
Comment 6 Francesco Turco 2016-10-06 14:39:42 UTC
I upgraded to mail-client/thunderbird-45.4.0 from the official repository but I still cannot start it due to a segmentation fault.
Comment 7 Ian Stakenvicius (RETIRED) gentoo-dev 2016-10-06 14:41:47 UTC
(In reply to Francesco Turco from comment #6)
> I upgraded to mail-client/thunderbird-45.4.0 from the official repository
> but I still cannot start it due to a segmentation fault.

Sorry for the delay, however the flags we need to adjust to fix this are still pending.  We will post back to this bug as soon as it's resolved.
Comment 8 Jory A. Pratt gentoo-dev 2016-10-09 14:14:57 UTC
Created attachment 449666 [details, diff]
gcc-6 support patch

Feel free to apply and test, please let us know your results.
Comment 9 Ian Stakenvicius (RETIRED) gentoo-dev 2016-10-09 14:37:13 UTC
(In reply to Jory A. Pratt from comment #8)
> Created attachment 449666 [details, diff] [details, diff]
> gcc-6 support patch
> 
> Feel free to apply and test, please let us know your results.

I've just added this patch to the eclass on mozilla-overlay, to make it easier to test on other packages as well.
Comment 10 Francesco Turco 2016-10-09 16:15:48 UTC
The patch contains a small typo: fno-delete-null-pointer-checks should have a dash in front of it.

Testing it right now.
Comment 11 Jory A. Pratt gentoo-dev 2016-10-09 17:10:58 UTC
(In reply to Francesco Turco from comment #10)
> The patch contains a small typo: fno-delete-null-pointer-checks should have
> a dash in front of it.
> 
> Testing it right now.

You are absolutely correct, I posted the wrong version of patch sorry.
Comment 12 Francesco Turco 2016-10-09 17:41:10 UTC
I just finished rebuilding thunderbird-45-4-0. It doesn't crash anymore at startup.
Comment 13 Martin Wohlert 2016-10-14 08:20:40 UTC
I tried the patch with thunderbird-45.4.0 in official gentoo branch and now my Thunderbird works again.

So I think this patch (with the fixed dash) could go upstream.
Comment 14 Jory A. Pratt gentoo-dev 2016-10-16 16:21:44 UTC
I have just pushed the gcc-6 flag support to main tree thanks for reporting.