Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 424475 - dev-scheme/guile-1.8.8-r1 builds fails (pre-inst-guile segfaults) with gcc-4.6.3 and -finline-functions cflag (included in -O3)
Summary: dev-scheme/guile-1.8.8-r1 builds fails (pre-inst-guile segfaults) with gcc-4....
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal with 1 vote (vote)
Assignee: Marijn Schouten (RETIRED)
URL: http://debbugs.gnu.org/cgi/bugreport....
Whiteboard:
Keywords:
Depends on:
Blocks: gcc-4.6
  Show dependency tree
 
Reported: 2012-07-02 06:07 UTC by Ivan Bagaev
Modified: 2012-08-27 08:15 UTC (History)
6 users (show)

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


Attachments
complete build log (dev-scheme:guile-1.8.8-r1:20120702-054938.log,191.38 KB, text/plain)
2012-07-02 06:09 UTC, Ivan Bagaev
Details
build.log (build.log,160.41 KB, text/plain)
2012-07-02 08:29 UTC, Lars Wendler (Polynomial-C) (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ivan Bagaev 2012-07-02 06:07:56 UTC
not compile dev-scheme/guile-1.8.8 and dev-scheme/guile-1.8.8-r1

Reproducible: Always

Steps to Reproduce:
sudo emerge -1av guile

Actual Results:  
/bin/sh ../libtool --tag=CC   --mode=link x86_64-pc-linux-gnu-gcc -pthread -march=core2 -mcx16 -msahf -mpclmul -mpopcnt -mavx --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=6144 -mtune=generic -O3 -pipe -Wall -Wmissing-prototypes -pthread -Wl,-O1 -Wl,--as-needed -o guile guile-guile.o libguile.la -lgmp -lcrypt -lm -lltdl 
libtool: link: x86_64-pc-linux-gnu-gcc -pthread -march=core2 -mcx16 -msahf -mpclmul -mpopcnt -mavx --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=6144 -mtune=generic -O3 -pipe -Wall -Wmissing-prototypes -pthread -Wl,-O1 -Wl,--as-needed -o .libs/guile guile-guile.o  ./.libs/libguile.so -lgmp -lcrypt -lm /usr/lib64/libltdl.so -ldl -pthread
cat alist.doc arbiters.doc async.doc backtrace.doc boolean.doc chars.doc continuations.doc debug.doc deprecation.doc deprecated.doc discouraged.doc dynl.doc dynwind.doc environments.doc eq.doc error.doc eval.doc evalext.doc extensions.doc feature.doc fluids.doc fports.doc futures.doc gc.doc goops.doc gsubr.doc gc-mark.doc gc-segment.doc gc-malloc.doc gc-card.doc guardians.doc hash.doc hashtab.doc hooks.doc i18n.doc init.doc ioext.doc keywords.doc lang.doc list.doc load.doc macros.doc mallocs.doc modules.doc numbers.doc objects.doc objprop.doc options.doc pairs.doc ports.doc print.doc procprop.doc procs.doc properties.doc random.doc rdelim.doc read.doc root.doc rw.doc scmsigs.doc script.doc simpos.doc smob.doc sort.doc srcprop.doc stackchk.doc stacks.doc stime.doc strings.doc srfi-4.doc srfi-13.doc srfi-14.doc strorder.doc strports.doc struct.doc symbols.doc threads.doc throw.doc values.doc variable.doc vectors.doc version.doc vports.doc weaks.doc ramap.doc unif.doc dynl.doc filesys.doc posix.doc regex-posix.doc | GUILE="/var/tmp/portage/dev-scheme/guile-1.8.8-r1/work/guile-1.8.8/pre-inst-guile" ../scripts/snarf-check-and-output-texi          > guile-procedures.texi || { rm guile-procedures.texi; false; }
/bin/sh: line 1: 28593 Обрыв канала cat alist.doc arbiters.doc async.doc backtrace.doc boolean.doc chars.doc continuations.doc debug.doc deprecation.doc deprecated.doc discouraged.doc dynl.doc dynwind.doc environments.doc eq.doc error.doc eval.doc evalext.doc extensions.doc feature.doc fluids.doc fports.doc futures.doc gc.doc goops.doc gsubr.doc gc-mark.doc gc-segment.doc gc-malloc.doc gc-card.doc guardians.doc hash.doc hashtab.doc hooks.doc i18n.doc init.doc ioext.doc keywords.doc lang.doc list.doc load.doc macros.doc mallocs.doc modules.doc numbers.doc objects.doc objprop.doc options.doc pairs.doc ports.doc print.doc procprop.doc procs.doc properties.doc random.doc rdelim.doc read.doc root.doc rw.doc scmsigs.doc script.doc simpos.doc smob.doc sort.doc srcprop.doc stackchk.doc stacks.doc stime.doc strings.doc srfi-4.doc srfi-13.doc srfi-14.doc strorder.doc strports.doc struct.doc symbols.doc threads.doc throw.doc values.doc variable.doc vectors.doc version.doc vports.doc weaks.doc ramap.doc unif.doc dynl.doc filesys.doc posix.doc regex-posix.doc
     28594 Ошибка сегментирования                   | GUILE="/var/tmp/portage/dev-scheme/guile-1.8.8-r1/work/guile-1.8.8/pre-inst-guile" ../scripts/snarf-check-and-output-texi > guile-procedures.texi
make[3]: *** [guile-procedures.texi] Ошибка 1
make[3]: Выход из каталога `/var/tmp/portage/dev-scheme/guile-1.8.8-r1/work/guile-1.8.8/libguile'
make[2]: *** [all] Ошибка 2
make[2]: Выход из каталога `/var/tmp/portage/dev-scheme/guile-1.8.8-r1/work/guile-1.8.8/libguile'
make[1]: *** [all-recursive] Ошибка 1
make[1]: Выход из каталога `/var/tmp/portage/dev-scheme/guile-1.8.8-r1/work/guile-1.8.8'
make: *** [all] Ошибка 2
emake failed


emerge --info '=dev-scheme/guile-1.8.8-r1'                                                                                                                                                                                1 ↵
Portage 2.2.0_alpha114 (default/linux/amd64/10.0/desktop, gcc-4.6.3, glibc-2.15-r2, 3.4.4-gentoo-v1 x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-3.4.4-gentoo-v1-x86_64-Intel-R-_Core-TM-_i7-2630QM_CPU_@_2.00GHz-with-gentoo-2.1
Timestamp of tree: Mon, 02 Jul 2012 02:00:01 +0000
app-shells/bash:          4.2_p29
dev-java/java-config:     2.1.12
dev-lang/python:          2.7.3-r2, 3.2.3-r1
dev-util/cmake:           2.8.8-r3
dev-util/pkgconfig:       0.26
sys-apps/baselayout:      2.1-r1
sys-apps/openrc:          0.10.3
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.10.3, 1.11.5, 1.12.1
sys-devel/binutils:       2.22-r1
sys-devel/gcc:            4.6.3
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 3.4 (virtual/os-headers)
sys-libs/glibc:           2.15-r2
Repositories: gentoo xwing sunrise miramir
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA Oracle-BCLA-JavaSE AdobeFlash-10.3"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=core2 -mcx16 -msahf -mpclmul -mpopcnt -mavx --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=6144 -mtune=generic -O3 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="${EPREFIX}/etc/gconf /etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.4/ext-active/ /etc/php/cgi-php5.4/ext-active/ /etc/php/cli-php5.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=core2 -mcx16 -msahf -mpclmul -mpopcnt -mavx --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=6144 -mtune=generic -O3 -pipe"
DISTDIR="/mnt/gentoo/portage/distfiles"
EMERGE_DEFAULT_OPTS="--quiet-build=y --with-bdeps=y --autounmask=y --autounmask-write=y"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs candy config-protect-if-modified distlocks ebuild-locks fixlafiles news nodoc noinfo parallel-fetch parallel-install parse-eapi-ebuild-head preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="rsync://gentoo.bloodhost.ru/gentoo-distfiles http://mirror.neolabs.kz/gentoo/pub http://mirror.netcologne.de/gentoo/"
LANG="ru_RU.UTF-8"
LC_ALL=""
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en ru"
MAKEOPTS="-j8"
PKGDIR="/mnt/gentoo/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_EXTRA_OPTS="--quiet"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/mnt/gentoo/portage"
PORTDIR_OVERLAY="/mnt/gentoo/layman/xwing /mnt/gentoo/layman/sunrise /mnt/gentoo/layman/miramir"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa amd64 berkdb branding bzip2 cairo cdda cdr cli consolekit cracklib crypt cups cxx dbus dri dts dvd dvdr emboss encode exif fam firefox flac fontconfig fortran gdbm gif gnome-keyring gpm gtk gtk3 iconv ipv6 ithreads jpeg lcms libnotify mad mmx mng modules mp3 mp4 mpeg mudflap multilib ncurses nls nptl ogg opengl openmp pam pango pcre pdf png policykit ppds pppd python3 qt3support qt4 readline sdl session spell sse sse2 ssl ssse3 startup-notification svg tcpd threads tiff truetype udev udisks unicode upower usb vim-syntax vorbis wxwidgets x264 xattr xcb xinerama xml xorg xulrunner xv xvid 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 authn_alias authn_anon 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 deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" 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" GRUB_PLATFORMS="pc" INPUT_DEVICES="evdev synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en ru" PHP_TARGETS="php5-4" PYTHON_TARGETS="python2_7 python3_2" RUBY_TARGETS="ruby18 ruby19" USERLAND="GNU" VIDEO_CARDS="intel radeon i915 r600" 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, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, USE_PYTHON
Comment 1 Ivan Bagaev 2012-07-02 06:09:06 UTC
Created attachment 316943 [details]
complete build log
Comment 2 Ivan Bagaev 2012-07-02 06:10:30 UTC
emerge -pqv '=dev-scheme/guile-1.8.8-r1'  
[ebuild  N    ] dev-scheme/guile-1.8.8-r1  USE="nls regex threads -debug -debug-freelist -debug-malloc -deprecated -discouraged -emacs -networking"
Comment 3 Ivan Bagaev 2012-07-02 06:24:02 UTC
guile need to grub-2.00

# sudo emerge -pvuDNt grub 

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

[nomerge       ] app-emulation/virt-manager-0.9.1  USE="gnome-keyring policykit -sasl -spice" 
[ebuild     U  ]  sys-auth/polkit-0.106-r6 [0.106-r5] USE="gtk introspection nls pam -debug -examples -kde (-selinux) -systemd" 0 kB
[nomerge       ] sys-boot/grub-2.00  USE="device-mapper nls sdl truetype -custom-cflags -debug -efiemu -libzfs -mount -static" GRUB_PLATFORMS="pc -coreboot -efi-32 -efi-64 -emu -ieee1275 -multiboot -qemu -qemu-mips -yeeloong" 
[ebuild  N     ]  sys-devel/autogen-5.15  0 kB
[ebuild  N     ]   dev-scheme/guile-1.8.8-r1  USE="nls regex threads -debug -debug-freelist -debug-malloc -deprecated -discouraged -emacs -networking" 0 kB
Comment 4 Ivan Bagaev 2012-07-02 06:26:03 UTC
info from linux.org.ru
http://www.linux.org.ru/forum/general/7929935
Comment 5 Cyprien Nicolas (fulax) 2012-07-02 08:06:54 UTC
I can't reproduce the segmentation fault you got with the default CFLAGS.

Your CFLAGS looks a bit full.
Please try to strip some of them, like -O2 instead of -O3, in order to narrow down the issue. Thanks.
Comment 6 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2012-07-02 08:29:34 UTC
Created attachment 316955 [details]
build.log

build log without russian/cyrillic language (sorry but not all Gentoo devs are capable of russian writing/language).
Comment 7 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2012-07-02 08:41:33 UTC
Can you guys try to compile the package without "-march=core2" CFLAG?
Comment 8 Cyprien Nicolas (fulax) 2012-07-02 08:53:12 UTC
(In reply to comment #7)
> Can you guys try to compile the package without "-march=core2" CFLAG?

Reproduced using CFLAGS="-O2 -march=i686 -pipe -finline-functions"

Removing -finline-functions made the build successful.
I'm contacting upstream.
Comment 9 Cyprien Nicolas (fulax) 2012-07-02 09:10:25 UTC
I confirm that this seems specific to gcc-4.6.3.

Builds fine with gcc 4.5.3 and 4.7.1.
Comment 10 Cyprien Nicolas (fulax) 2012-07-02 18:43:31 UTC
Bug nailed down and reported upstream. See $URL for details.
Comment 11 Cyprien Nicolas (fulax) 2012-07-03 21:57:55 UTC
Upstream fix: http://git.savannah.gnu.org/cgit/guile.git/commit/?h=branch_release-1-8&id=62bc1072c19e81bb0f9e42a5034e7ab8c27d3b94

I added the patch to dev-scheme/guile-1.8.8-r2 in the lisp overlay.
Comment 12 Carlos Silva 2012-07-06 13:09:45 UTC
Currently not "buildable" on amd64 testing. hope it gets merged soon :)
Comment 13 Carlos Silva 2012-07-18 10:05:06 UTC
is there a problem merging this patch into portage? I'm currently unable to update since this package was marked *stable*. IMHO, a problem with a stable package should be fix asap... In this case, everything is identified but it's still not merged.
Comment 14 Cyprien Nicolas (fulax) 2012-07-18 10:25:44 UTC
(In reply to comment #13)
> is there a problem merging this patch into portage? I'm currently unable to
> update since this package was marked *stable*. IMHO, a problem with a stable
> package should be fix asap... In this case, everything is identified but
> it's still not merged.


Workaround, depending on your current configuration:

- add -fno-inline-functions to your CFLAGS
- remove -finline-functions from CFLAGS
- use -O2 instead of -O3 in CFLAGS
Comment 15 Carlos Silva 2012-07-18 10:48:23 UTC
@Cyprien
Yes, I'm aware of that work around. The thing is, it's *not* a fix, and a *proper* fix is available. Also, to make it worse, the package is marked *stable*. It's a simple patch already merged upstream.
Comment 16 白川間瀬流 2012-07-30 14:15:46 UTC
if the patch was accepted upstream and this package is marked as stable it really should be included.

I mean other packages are patched to death to get them working and this package is marked as stable and not working, even when there is a upstream patch.
Comment 17 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2012-08-27 08:15:57 UTC
+  27 Aug 2012; Kacper Kowalik <xarthisius@gentoo.org>
+  +files/guile-1.8.8-gcc46.patch, guile-1.8.8-r1.ebuild:
+  Backport upstream patch to fix SIGSEGV with gcc-4.6 wrt #424475 by Ivan Bagaev
+  <gmiramir@gmail.com> Thanks to Cyprien Nicolas (fulax)
+  <c.nicolas+bugs@gmail.com> for detailed analysis and finding patch. Acked by
+  hkBst