Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 389937 - Segmentation fault when compiling dev-lang/v8-3.6.6.6 with gcc-4.5.2?
Summary: Segmentation fault when compiling dev-lang/v8-3.6.6.6 with gcc-4.5.2?
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Chromium Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-09 08:34 UTC by Weonbin
Modified: 2011-11-23 19:31 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Weonbin 2011-11-09 08:34:13 UTC
The installation of dev-lang/v8-3.6.6.6 fails because of a segmentation fault, thus preventing chromium from being updated.

Here is the culpirit command :
"/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/mksnapshot" --log-snapshot-positions --logfile "/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/obj.target/geni/snapshot.log" "/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/obj.target/geni/snapshot.cc"
segmentation fault   --log-snapshot-positions --logfile




Full log :
>>> Compiling source in /var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6 ...
make -j4 V=1 library=shared werror=no soname_version=3.6.6.6 snapshot=on x64.release 
make[1] : on entre dans le répertoire « /var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out »
  export LD_LIBRARY_PATH=/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/lib.host:/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/lib.target:$LD_LIBRARY_PATH; cd ../tools/gyp; mkdir -p /var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/obj.target/geni; "/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/mksnapshot" --log-snapshot-positions --logfile "/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/obj.target/geni/snapshot.log" "/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/obj.target/geni/snapshot.cc"
/bin/sh : ligne 1 : 14461 Erreur de segmentation  "/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/mksnapshot" --log-snapshot-positions --logfile "/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/obj.target/geni/snapshot.log" "/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/obj.target/geni/snapshot.cc"
make[1]: *** [/var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out/x64.release/obj.target/geni/snapshot.cc] Erreur 139
make[1] : on quitte le répertoire « /var/tmp/portage/dev-lang/v8-3.6.6.6/work/v8-3.6.6.6/out »
make: *** [x64.release] Erreur 2
emake failed

Reproducible: Always

Steps to Reproduce:
emerge dev-lang/v8



emerge --info

Portage 2.1.10.22 (default/linux/amd64/10.0/desktop/kde, gcc-4.5.2, glibc-2.13-r4, 3.0.4 x86_64)
=================================================================
System uname: Linux-3.0.4-x86_64-Intel-R-_Core-TM-2_Quad_CPU_Q6700_@_2.66GHz-with-gentoo-2.1
Timestamp of tree: Tue, 08 Nov 2011 23:30:01 +0000
app-shells/bash:          4.2_p10
dev-java/java-config:     2.1.11-r3
dev-lang/python:          2.6.7-r2, 2.7.2-r3, 3.2.2
dev-util/cmake:           2.8.5-r2
dev-util/pkgconfig:       0.26
sys-apps/baselayout:      2.1
sys-apps/openrc:          0.9.3-r1
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13::<unknown repository>, 2.68
sys-devel/automake:       1.5-r1, 1.8.5-r4, 1.9.6-r3, 1.10.3, 1.11.1-r1
sys-devel/binutils:       2.21.1-r1
sys-devel/gcc:            4.5.2
sys-devel/gcc-config:     1.4.1-r1
sys-devel/libtool:        2.4-r3
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 2.6.39 (virtual/os-headers)
sys-libs/glibc:           2.13-r4
Repositories: gentoo sunrise bitcoin wavilen local
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/maven-bin-3.0/conf"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs distlocks ebuild-locks fixlafiles fixpackages news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS=""
GENTOO_MIRRORS="http://gentoo.mirrors.hoobly.com/ http://mirror.uni-c.dk/pub/gentoo/ http://mirror.muntinternet.net/pub/gentoo/ http://gentoo.cs.nctu.edu.tw/gentoo/ http://lug.mtu.edu/gentoo/"
LANG="C"
LC_ALL="C"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en fr ja ko"
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/sunrise /var/lib/layman/bitcoin /var/lib/layman/wavilen /var/paludis/repositories/local"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac accessibility acl acpi aiglx alsa amd64 apache2 apng autoipd avahi bash-completion berkdb bluetooth branding bzip2 cairo calendar cdda cdr chm cjk cli connman consolekit cracklib cran crypt ctype cups curl custom-cflags cxx dbus declarative dirac djvu dri dts dv dvb dvd dvdr dvdread ebook effects emboss encode exif extensions extras faac faad facebook fam ffmpeg firefox firefox3 flac fontconfig fortran frei0r ftp gconf gcrypt gd gdbm gdu geolocation gif gles glib glitz glsa gnome gphoto2 gpm gstreamer gtk gtk3 hash hbci htmlhandbook http httpd iconv icu id3tag imap imlib immqt-bc inquisitio ipv6 jabber java jpeg kde kde4 kdehiddenvisibility kdrive kipi kqemu lame lcms ldap libcaca libnotify libwww llvm lm_sensors lua mad maildir matroska melt mikmod mime minizip mmx mmxext mng mod_pubsub mod_statsdx modules mozilla mp3 mp4 mpeg mplayer msn msnextras mudflap multilib musepack mysql mysqli nautilus ncurses network networkmanager nls npp nptl nptlonly nsplugin nxclient objc ofono ofx ogg openal openexr opengl openmp openssl pam pango pcre pdf phonon pink plasma png policykit portage posix postgres ppds pppd prediction pulseaudio pyste python-bindings qalculate qemu qt3support qt4 qwt readline resolvconf rss rtsp ruby ruby-bindings samba sasl schroedinger scim sdl secure-delete session sip skins skype slp smi sndfile soap sockets socks5 soup sox speex spell sql sqlite sqlite3 sse sse2 ssl startup-notification stream stun svg symlink sysfs sysvipc taglib tcpd theora threads threadsafe tiff tordns transparency truetype udev unicode usb utils vaapi vde vhosts video vim-syntax visibility visualization vnc vorbis wav webkit windeco wxwidgets wxwindows x264 xcb xcomposite xinerama xml xmlreader xmlrpc xmlwriter xmp xorg xosd xpm xscreensaver xulrunner xv xvid zip zlib zsh-completion" ALSA_CARDS="hda-intel" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" DRACUT_MODULES="plymouth" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en fr ja ko" PHP_TARGETS="php5-3" QEMU_SOFTMMU_TARGETS="i386 x86_64" QEMU_USER_TARGETS="i386 x86_64" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="i810 vesa nouveau" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Tolga Dalman 2011-11-09 09:35:56 UTC
I cannot confirm this bug - v8 compiles fine here (quite similar system).
Have you run revdep-rebuild to cross check any outstanding problems ?
Furthermore, I noticed you have repositories other than gentoo activated. Perhaps this might be the cause ?
Comment 2 Agostino Sarubbo gentoo-dev 2011-11-09 10:11:38 UTC
PLease attach next time log compile with LC_ALL=C and as attachment
Comment 3 Mike Gilbert gentoo-dev 2011-11-09 14:57:56 UTC
I can't reproduce that either.

My French is very bad, so please attach an English build log.
Comment 4 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-11-10 16:11:03 UTC
Does replacing "snapshot=${snapshot} \" with "snapshot=no \" in the ebuild fix the problem for you?

Note that I assume you know how to create a local overlay and use repoman manifest / ebuild digest.
Comment 5 Michal Januszewski (RETIRED) gentoo-dev 2011-11-13 16:07:06 UTC
(In reply to comment #4)
> Does replacing "snapshot=${snapshot} \" with "snapshot=no \" in the ebuild fix
> the problem for you?
> 
> Note that I assume you know how to create a local overlay and use repoman
> manifest / ebuild digest.

I ran into the same bug.  snapshot=no didn't help.
Comment 6 Michal Januszewski (RETIRED) gentoo-dev 2011-11-13 16:17:02 UTC
(In reply to comment #5)
> (In reply to comment #4)
> > Does replacing "snapshot=${snapshot} \" with "snapshot=no \" in the ebuild fix
> > the problem for you?
> > 
> > Note that I assume you know how to create a local overlay and use repoman
> > manifest / ebuild digest.
> 
> I ran into the same bug.  snapshot=no didn't help.

Switching to gcc-4.6.0 seems to help.  I experienced the bug with gcc-4.5.2.
Comment 7 Mike Gilbert gentoo-dev 2011-11-15 00:47:11 UTC
Well, gcc-4.5.2 seems to be a pattern then.

It builds fine for me with gcc-4.5.3-r1.
Comment 8 Weonbin 2011-11-15 01:27:09 UTC
I confirm that it's gcc related.
I updated (painfully) gcc to 4.5.3-r1, and v8 just built flawlessly.
It would be a good thing to blacklist this version of gcc for this ebuild.
Comment 9 Mike Gilbert gentoo-dev 2011-11-15 03:48:37 UTC
(In reply to comment #8)
> I updated (painfully) gcc to 4.5.3-r1

Painful on a quad-core processor?

It seems strange to me that you would be using gcc 4.5.2; 4.5.3 has been stable for over a month. Did you have it masked or something?

> It would be a good thing to blacklist this version of gcc for this ebuild.

I guess we could add DEPEND=">=sys-devel/gcc-4.5.3". Paweł?
Comment 10 Weonbin 2011-11-15 03:59:36 UTC
(In reply to comment #9)
> (In reply to comment #8)
> > I updated (painfully) gcc to 4.5.3-r1
> 
> Painful on a quad-core processor?
> 
> It seems strange to me that you would be using gcc 4.5.2; 4.5.3 has been stable
> for over a month. Did you have it masked or something?
> 
Yes I masked it because of bug 390039 which prevented the upgrade.
it took me some time to get my system to compile gcc compile without errors.
Comment 11 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-11-15 07:32:04 UTC
(In reply to comment #9)
> I guess we could add DEPEND=">=sys-devel/gcc-4.5.3". Paweł?

It's not perfect either, one can have 4.5.3 installed but 4.5.2 still active.

I think a die hook (similar to www-client/chromium's one) could be better, i.e. check the active gcc version and warn about problems before reporting a bug.

Actually if we can, a pkg_pretend check would be even better. We should be able to see the active version of gcc and just call die.
Comment 12 Mike Gilbert gentoo-dev 2011-11-21 00:16:20 UTC
(In reply to comment #11)
> Actually if we can, a pkg_pretend check would be even better. We should be able
> to see the active version of gcc and just call die.

How about this?

pkg_pretend() {
    local gccver=$(gcc-fullversion)
    if [[ ${gccver} = 4.5.2 ]]; then
        eerror "The currently selected version of gcc is known to segfault when 
building this"
        eerror "version of V8. Please use at least gcc-4.5.3."
        die "gcc-${gccver} detected"
    fi
}
Comment 13 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-11-21 07:38:55 UTC
(In reply to comment #12)
> How about this?
> 
> pkg_pretend() {
>     local gccver=$(gcc-fullversion)
>     if [[ ${gccver} = 4.5.2 ]]; then
>         eerror "The currently selected version of gcc is known to segfault when 
> building this"
>         eerror "version of V8. Please use at least gcc-4.5.3."
>         die "gcc-${gccver} detected"
>     fi
> }

Generally LGTM, one comment: is only 4.5.2 known to cause problems, or older versions are problematic too? In the latter case we could ban everything older than 4.5.3.
Comment 14 Mike Gilbert gentoo-dev 2011-11-23 19:31:04 UTC
I'm not sure if other gcc versions are affected, so I just kept the simple equality check.

Added to 3.6.6.5, 3.6.6.6, 3.7.6, and 3.7.7.