I've tried emerging openoffice numerous times and always results in the failure below. ... cleaning the output tree ... ... removing directory /var/tmp/portage/app-office/openoffice-3.1.1/work/ooo/build/ooo310-m19/instsetoo_native/util/OpenOffice//zip/en-US ... ... removing directory /var/tmp/portage/app-office/openoffice-3.1.1/work/ooo/build/ooo310-m19/instsetoo_native/util/OpenOffice//gid_Starregistry_Services_Rdb_servicesrdb/en-US_witherror_1 ... ************************************************** ERROR: ERROR: Could not register all components for file services.rdb (gid_Starregistry_Services_Rdb)! in function: create_services_rdb ************************************************** ************************************************** ERROR: Saved logfile: /var/tmp/portage/app-office/openoffice-3.1.1/work/ooo/build/ooo310-m19/instsetoo_native/util/OpenOffice//logging/en-US/log_OOO310_en-US.log ************************************************** Mon Nov 9 06:46:51 2009 (00:50 min.) Failed to install: at ./ooinstall line 153. make: *** [install] Error 1 * * ERROR: app-office/openoffice-3.1.1 failed. * Call stack: * ebuild.sh, line 49: Called src_install * environment, line 5297: Called die * The specific snippet of code: * make DESTDIR="${D}" install || die "Installation failed!"; * The die message: * Installation failed! * * If you need support, post the topmost build error, and the call stack if relevant. * A complete build log is located at '/var/log/portage/app-office:openoffice-3.1.1:20091109-035946.log'. * The ebuild environment file is located at '/var/tmp/portage/app-office/openoffice-3.1.1/temp/environment'. * !!! When you file a bug report, please include the following information: GENTOO_VM=sun-jdk-1.6 CLASSPATH="" JAVA_HOME="/opt/sun-jdk-1.6.0.15" JAVACFLAGS="-source 1.5 -target 1.5" COMPILER="" and of course, the output of emerge --info * QA Notice: Unrecognized configure options: * * configure: WARNING: unrecognized options: --without-system-cairo, --enable-pam, --with-java * configure: WARNING: unrecognized options: --without-system-cairo, --enable-pam, --with-java * configure: WARNING: unrecognized options: --with-system-rhino, --with-rhino-jar, --disable-gstreamer, --without-writer2latex, --with-system-redland, --with-distro, --with-arch, --with-srcdir, --with-num-cpus, --without-binsuffix, --with-installed-ooo-dirname, --with-tag, --with-drink, --enable-strip, --disable-access, --disable-post-install-scripts, --enable-extensions * configure: WARNING: unrecognized options: --with-system-rhino, --with-rhino-jar, --disable-gstreamer, --without-writer2latex, --with-system-redland, --with-distro, --with-arch, --with-srcdir, --with-num-cpus, --without-binsuffix, --with-installed-ooo-dirname, --with-tag, --with-drink, --enable-strip, --disable-access, --disable-post-install-scripts, --enable-extensions >>> Failed to emerge app-office/openoffice-3.1.1, Log file: >>> '/var/log/portage/app-office:openoffice-3.1.1:20091109-035946.log' The output of emerge --info Portage 2.1.6.13 (default/linux/x86/10.0, gcc-4.3.4, glibc-2.9_p20081201-r2, 2.6.26-gentoo-r3 i686) ================================================================= System uname: Linux-2.6.26-gentoo-r3-i686-Intel-R-_Pentium-R-_4_CPU_2.53GHz-with-gentoo-1.12.11.1 Timestamp of tree: Mon, 02 Nov 2009 02:30:02 +0000 app-shells/bash: 4.0_p28 dev-java/java-config: 2.1.9-r1 dev-lang/python: 2.6.2-r1 dev-python/pycrypto: 2.0.1-r8 dev-util/cmake: 2.6.4 sys-apps/baselayout: 1.12.11.1 sys-apps/sandbox: 1.6-r2 sys-devel/autoconf: 2.13, 2.63-r1 sys-devel/automake: 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2 sys-devel/binutils: 2.18-r3 sys-devel/gcc-config: 1.4.1 sys-devel/libtool: 2.2.6a virtual/os-headers: 2.6.27-r2 ACCEPT_KEYWORDS="x86" CBUILD="i686-pc-linux-gnu" CFLAGS="-O3 -march=pentium4 -funroll-loops -fprefetch-loop-arrays -pipe" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config /var/lib/hsqldb" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /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 /etc/udev/rules.d" CXXFLAGS="-O3 -march=pentium4 -funroll-loops -fprefetch-loop-arrays -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch" GENTOO_MIRRORS="http://mirror.datapipe.net/gentoo http://distro.ibiblio.org/pub/linux/distributions/gentoo/ ftp://gentoo.chem.wisc.edu/gentoo/ http://gentoo.arcticnetwork.ca/" LANG="en_CA.utf8" LDFLAGS="-Wl,-O1" LINGUAS="en" MAKEOPTS="-j1" 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" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="3dnow 3dnowext X a52 aac accessibility acl alsa bash-completion berkdb bitmap-fonts bzip2 cdr cli cracklib crypt cscope css cups dbus dga divx4linux doc dri dts dvd dvdr dvdread encode ffmpeg flac fortran gdbm gif gimp gimpprint gnutls gpm hal iconv ipod ipv6 jadetex java jpeg kde ldap mmx mmx2 mng modules mudflap mysql ncurses networkmanager nls nptl nptlonly nsplugin ntfs nvidia ofx opengl openmp oss pam pcre perl ppds pppd python qt3support qt4 quotesi readline reflection regex reiserfs rtc sasl session spl sse sse2 ssl svg sysfs tcpd tiff tk truetype-fonts type1-fonts unicode usb userlocales utempter vim-syntax win32codecs wmf x86 xorg xvid zlib" ALSA_CARDS="emu10k1" 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 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" ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en" USERLAND="GNU" VIDEO_CARDS="nvidia vga vesa fbdev" Unset: CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY Please let me know if the complete log file attachment is required. Reproducible: Always Steps to Reproduce: 1. emerge --sync 2. emerge openoffice
*** Bug 292523 has been marked as a duplicate of this bug. ***
This is a regcomp crash which is usually triggered by over-optimizing your CFLAGS, try to build with some more generic settings Reopen if the problem remains when building with generic settings
I have retried with pretty basic optimization settings. -O2 -march=pentium4. The emerge --info is below. This is 100% reproducible. Please let me know how I can help assist in debug. Thanks, Tash # emerge --info Portage 2.1.6.13 (default/linux/x86/10.0, gcc-4.3.4, glibc-2.9_p20081201-r2, 2.6.26-gentoo-r3 i686) ================================================================= System uname: Linux-2.6.26-gentoo-r3-i686-Intel-R-_Pentium-R-_4_CPU_2.53GHz-with-gentoo-1.12.13 Timestamp of tree: Fri, 11 Dec 2009 21:30:01 +0000 app-shells/bash: 4.0_p35 dev-java/java-config: 2.1.9-r1 dev-lang/python: 2.6.4 dev-python/pycrypto: 2.0.1-r8 dev-util/cmake: 2.6.4-r3 sys-apps/baselayout: 1.12.13 sys-apps/sandbox: 1.6-r2 sys-devel/autoconf: 2.13, 2.63-r1 sys-devel/automake: 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2 sys-devel/binutils: 2.18-r3 sys-devel/gcc-config: 1.4.1 sys-devel/libtool: 2.2.6b virtual/os-headers: 2.6.27-r2 ACCEPT_KEYWORDS="x86" CBUILD="i686-pc-linux-gnu" CFLAGS="-O2 -march=pentium4" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config /var/lib/hsqldb" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /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 /etc/udev/rules.d" CXXFLAGS="-O2 -march=pentium4" DISTDIR="/usr/portage/distfiles" FEATURES="distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch" GENTOO_MIRRORS="http://mirror.datapipe.net/gentoo http://distro.ibiblio.org/pub/linux/distributions/gentoo/ ftp://gentoo.chem.wisc.edu/gentoo/ http://gentoo.arcticnetwork.ca/" LANG="en_CA.utf8" LDFLAGS="-Wl,-O1" LINGUAS="en" MAKEOPTS="-j1" 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" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="3dnow 3dnowext X a52 aac accessibility acl alsa bash-completion berkdb bitmap-fonts bzip2 cdr cli cracklib crypt cscope css cups cxx dbus dga divx4linux doc dri dts dvd dvdr dvdread encode ffmpeg flac fortran gdbm gif gimp gimpprint gnutls gpm hal iconv ipod ipv6 jadetex java jpeg kde ldap mmx mmx2 mng modules mudflap mysql ncurses networkmanager nls nptl nptlonly nsplugin ntfs nvidia ofx opengl openmp oss pam pcre perl ppds pppd python qt3support qt4 quotesi readline reflection regex reiserfs rtc sasl session spl sse sse2 ssl svg sysfs tcpd tiff tk truetype-fonts type1-fonts unicode usb userlocales utempter vim-syntax win32codecs wmf x86 xorg xvid zlib" ALSA_CARDS="emu10k1" 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 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" ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="nvidia vga vesa fbdev" Unset: CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Looks like upstream have this at: http://qa.openoffice.org/issues/show_bug.cgi?id=80979
Maybe not. The log file mentioned has: ERROR: /var/tmp/portage/app-office/openoffice-3.1.1/work/ooo/build/ooo310-m19/solver/310/unxlngi6.pro/bin/regcomp -register -br /var/tmp/portage/app-office/openoffice-3.1.1/work/ooo/build/ooo310-m19/solver/310/unxlngi6.pro/bin/types.rdb -br /var/tmp/portage/app-office/openoffice-3.1.1/work/ooo/build/ooo310-m19/solver/310/unxlngi6.pro/bin/pyuno_services.rdb -r /var/tmp/portage/app-office/openoffice-3.1.1/work/ooo/build/ooo310-m19/instsetoo_native/util/OpenOffice//gid_Starregistry_Services_Rdb_servicesrdb/en-GB_en-US_en-US_inprogress_1/services.rdb -c vnd.openoffice.pymodule:mailmerge -l com.sun.star.loader.Python 2>&1 |
oh, the segfault is in this instruction: 0xb7181e26 <PyString_Format+4070>: movdqa %xmm0,-0x178(%ebp) Probably an alignment issue.
Yes, the stack is misaligned: (gdb) info reg eax 0x5 5 ecx 0x81684d3 135693523 edx 0x29 41 ebx 0xb7251ff4 -1222303756 esp 0xbfff1b3c 0xbfff1b3c ebp 0xbfff1cf4 0xbfff1cf4 esi 0x81684d9 135693529 edi 0x122 290 eip 0xb7181e26 0xb7181e26 <PyString_Format+4070> eflags 0x210246 [ PF ZF IF RF ID ] cs 0x73 115 ss 0x7b 123 ds 0x7b 123 es 0x7b 123 fs 0x0 0 gs 0x33 51
Bad frame is: #87 0xb776e419 in privateSnippetExecutorGeneral () from /var/tmp/portage/app-office/openoffice-3.1.1/work/ooo/build/ooo310-m19/solver/310/unxlngi6.pro/lib/libgcc3_uno.so
build/ooo310-m19/bridges/source/cpp_uno/gcc3_linux_intel/call.s: .globl privateSnippetExecutorGeneral .type privateSnippetExecutorGeneral,@function privateSnippetExecutorGeneral: .LFBg: movl %esp,%ecx pushl %ebp # proper stack frame needed for exception handling .LCFIg0: movl %esp,%ebp .LCFIg1: subl $0x4,%esp # 32bit returnValue pushl %esp # 32bit &returnValue pushl %ecx # 32bit pCallStack pushl %edx # 32bit nVtableOffset pushl %eax # 32bit nFunctionIndex call cpp_vtable_call movl 16(%esp),%eax # 32bit returnValue leave ret .LFEg: .size privateSnippetExecutorGeneral,.-privateSnippetExecutorGeneral Obviously, this is illegal on modern x86 ABIs; stack frames must be kept 128-bit aligned.
Created attachment 216011 [details, diff] cpp_uno-align.patch This should do the trick. The call.s asm is fairly simple; since we're always pushing 4 words onto the stack before the call I just have to align it to 128 bits beforehand. uno2cpp.cxx is a little trickier, because an arbitrary number of words are pushed. I drop the stack to 128-bits and then drop it again such that after the words are pushed it will be back in alignment - i.e. by ((n*4 - 4) % 16 - 12), so as not to waste space when n is divisible by 4.
Created attachment 216033 [details, diff] cpp_uno-align.diff Patch suitable for placing in patches/hotfixes directory (as cpp_uno-align.diff).
@Ed: Could you please also file this upstream an put the link here?
Created upstream bug http://www.openoffice.org/issues/show_bug.cgi?id=108371
@Ed: Would you mind to check x86_64 arch bridges code, too? That would be the path gcc3_linux_intel vs. gcc3_linux_x86-64. Thank you!
(In reply to comment #15) > @Ed: Would you mind to check x86_64 arch bridges code, too? That would be the > path gcc3_linux_intel vs. gcc3_linux_x86-64. Thank you! It looks OK from what I know of x86-64, which isn't much.
(In reply to comment #12) > Created an attachment (id=216033) [details] > cpp_uno-align.diff > > Patch suitable for placing in patches/hotfixes directory (as > cpp_uno-align.diff). > I tried building 3.1.1 with the patch on my overlay (/usr/local/portage), but end up with the exact same seg fault. I feel like I didn't do something correctly in regards to the hotfix. Here's what I did: 1. cp'ed everything in app-office/openoffice/ to my local overlay 2. Added cpp_uno-align.diff to the overlay's app-office/openoffice/files/ 3. Edited the openoffice-3.1.1.ebuild to insert this on line 246: cp -f "${FILESDIR}/cpp_uno-align.diff" "${S}/patches/hotfixes" || die since it is a "hotfix" 4. Then ebuild openoffice-3.1.1.ebuild digest emerge log: http://pastebin.com/f66c47479 emerge --info: http://pastebin.com/f7afd1ed6
Created attachment 221871 [details] Similar problem on x86_64 I am having what appears to be the same problem on my X86_64 system, i.e., segmentation fault in call to regcomp (with a huge list of long pathnames on the command line). Any suggestions how to work around it?
Seems that this bug has been resolved in 3.2.0. It compiles fine on x86_64.
OOo 3.2.1 still fails for me with this error. The fix in upstream went only for 3.3.0 branch, not 3.2.x.
Created attachment 236259 [details, diff] upstream patch Upstream patch that works for me; needs to be copied to ooo-build's hotfixes dir.
(In reply to comment #21) > Created an attachment (id=236259) [details] > upstream patch > > Upstream patch that works for me; needs to be copied to ooo-build's hotfixes > dir. > Unfortunately the upstream patch didn't fixed the problem for me (both on Pentium-M and Athlon-MP architectures). I verified in the logs and opening the file themselves that the patch gets applied correctly. However install phase fails as before, while the logs look the same - like I've reported and attached in a duplicate of this bug: https://bugs.gentoo.org/show_bug.cgi?id=307879 The problem might be aggravated by the use of Hardened toolchain in my case. I'm interested in any further patches to try out. I've been suffering because of this for months now. Meanwhile the good old openoffice 3.1.1 still compiles fine on both of my hardened systems. Regards: Dw.
I am seeing the same error on nomal x86 gentoo for OO 3.2.1. With -j1 and reduced optimizations aswell.
(In reply to comment #23) > I am seeing the same error on nomal x86 gentoo for OO 3.2.1. With -j1 and > reduced optimizations aswell. > So you are using a non-hardened install... Wonderful! I'm sorry for being happy, but if hits the non-hardened folk as well, there's a better chance that it'll got enough attention. It may be corrected eventually.
I don't think it applies to everyone, but I had the same error and resolved it by recompiling python:2.6 with reduced CFLAGS. My usual CFLAGS are -O3 -march=native -fomit-frame-pointer. The reduced CFLAGS I used are -O2 -march=native. After a failed openoffice emerge I found regcomp[15696] general protection ip:4112ffed sp:bfe11b2c error:0 in libpython2.6.so.1.0[41035000+127000] in my dmesg. First, I reemerged openoffice with the reduced CFLAGS and I got the same error. Then I reemerge python:2.6 and openoffice with the reduced CFLAGS and everything went fine.
I react for the recent post talking about openoffice 3.2.1 (original bug report was about 3.1.1). My installation is normal gentoo x86, and i ran into same error. In my opinion -j1 does not do much, and does not matter i set -O2, because in the log i see -O1 everywhere (probably the installer overwrites it, since "openoffice is a very fragile build when it comes to CFLAGS"). Also it is worth mentioning that previous version (3.2.0) of openoffice compiled without error, without -j1 and with -O3 (250 packages were upgraded, no idea which could affect compilation of openoffice), so the problem is probably somewhere else. I did not try any patch outside of portage tree, thus can not say if it solves the problem or not. Sadly the "magic" tools like revdep-rebuild, perl-cleaner, and lafilefixer did not help either.
(In reply to comment #25) > I don't think it applies to everyone, but I had the same error and resolved it > by recompiling python:2.6 with reduced CFLAGS. > > My usual CFLAGS are -O3 -march=native -fomit-frame-pointer. The reduced CFLAGS > I used are -O2 -march=native. > > After a failed openoffice emerge I found regcomp[15696] general protection > ip:4112ffed sp:bfe11b2c error:0 in libpython2.6.so.1.0[41035000+127000] in my > dmesg. > After I hit this error for the umpteenth time, I finally found this bug and your comment. I looked into dmesg and found the general protection fault, too. I the followed you advice and reduced the CFLAGS for python:2.6 from -O3 to -O2. And reemerged it. The interesting part follows: I did _not_ re-emerge openoffice, but ran ebuild /usr/portage/openoffice/openoffice-3.2.1-r1 install and it went through just fine! So the bug does not seem to have anything to do with the /code/ of OOO, but the usage of python during install. As this is the only package I know of that has problems with the python:2.6/-O3 combination, it just might be a misuse of python somewhere, that just not shows up with anything but -O3 on python.
This sweet bug is fixed by lo-3.4.2.2 that uses completely new build system :) Please test and reopen the bug if i am wrong :)
*** Bug 307879 has been marked as a duplicate of this bug. ***
*** Bug 340937 has been marked as a duplicate of this bug. ***