From owner-freebsd-office@FreeBSD.ORG Sun Aug 24 19:50:18 2014 Return-Path: Delivered-To: office@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 6A92C3D0 for ; Sun, 24 Aug 2014 19:50:18 +0000 (UTC) Received: from nm2-vm1.bullet.mail.bf1.yahoo.com (nm2-vm1.bullet.mail.bf1.yahoo.com [98.139.213.158]) by mx1.freebsd.org (Postfix) with ESMTP id 17E2B3EA3 for ; Sun, 24 Aug 2014 19:50:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1408909810; bh=d72FeVNf/T1LiPz4y67BcqAnz+QF4RUQBvn+fQRUbXY=; h=Received:Received:Received:X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Content-Type:Mime-Version:Subject:From:In-Reply-To:Date:Cc:Message-Id:References:To:X-Mailer:From:Subject; b=jFQIVPmlWc5EvkvNQ1RVcwzhEejwrrNHJqTRC6IYQFkjI8cw9nYTULcqIWb9kU2E296e3avbvYxld1hXrvxjMju11nSozu9Cfag9zaKmLunpw2sqijTka42AXWIsJAuV/A1pFv4fKGF62kZagEd+M1XjwAt2jtLaruqK68MSj3PHX2pPNqHVmOJPyJ/etWJWxVZnVnjSUpdoRnwSKX1VgTIuvXWlNRI1FRY4BlJl5ZFkd+O5ER5skbkrIWkVUEeck16QQA/ObJWjAMuPc6SqS66hutXUMVrtEXqMmED7oev+gWOXVREVmvNZ6tg6U/6pJqRbaIf5j1oxeLltINOmrw== DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s2048; d=yahoo.com; b=SyiTY+UJRQmRdQXTBgKNjgcwWcEQhCaWNKDTe94LkjbnH3QMNFcIzc19hmylvsIQquTJ9UpHW8P16IQlN1CoFGQxmKzomeFAC1/uaSN+GY5xR5AmCnAGGy+zEF/PxjoKlzslYJ45agdOveTIMSZ+GQj09NBM81Ho2j6cgnBh4dae+4QcnrQj2SW6Ya05UkEhMMI+zMD0dOvPjIJESbBWy4ZBJMmnyfNeDDVgrkf73jjOqXQcKt3XwObHhOaauD0v3z8fU3ClbXm7uQFmYKSkpnpSgO+GxfFPKvBF2liYaaGd0kTQvBj4opUNfH2wLr0hZ0e5jyRe8LGfZQMBqgD6Sg==; Received: from [98.139.214.32] by nm2.bullet.mail.bf1.yahoo.com with NNFMP; 24 Aug 2014 19:50:10 -0000 Received: from [98.139.211.193] by tm15.bullet.mail.bf1.yahoo.com with NNFMP; 24 Aug 2014 19:50:10 -0000 Received: from [127.0.0.1] by smtp202.mail.bf1.yahoo.com with NNFMP; 24 Aug 2014 19:50:10 -0000 X-Yahoo-Newman-Id: 923678.82750.bm@smtp202.mail.bf1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: Am1fws8VM1ku.NbX1ce1xjERRWj8BUZ_AGSbUV3RICGRH.V unoUhMHF3DtppneJUum4LhUIwT.QADgfShPvVHYwo9AMuDxPCRJeaoJiYBCb V_ejO7wbpEq6oxcgAIvnV0F9lMyn9sSQ7fnf3MOrAKXi8K5DrufJU5P9jvXA Ez8SB0vQ4rUS2wGqc48UuCQEHnm178ovU7V5.Lu6mO2AZNQSt3ocDRp4CF4r N9IAqLcV9S1.txaIx1GPweXuJPw_oXxrIQEz_pxDbMWjy38UQNYQCkRAg_IF Vnsvr6wBWx5E.fuwAjqLwkfIgsbOD1XT9EhgaebaUacsWYYtcTB1Ks9wZ0hc oeSmwWEcYT60IYEIKTYH0.y2R8FX09aVmEBrw1MSeSAD3VZ0MzOo76eHEb7M IUtltj4ooRH0e3S1TYrC5dazk6y5FhgM53FJSoXPoOXxZdG.01puwFSRVGl0 IUdS3aeKQnsqtby7oGFtJs3enMOm_39m0UQsrSmnJReglFZSUDRfh4N6wcBT sSHaCPRQboZnJphBQs6NK_nYmN9_2NX5VHrKUjUUZ2D.dRPSTecLBlzu6Zjc y6nyVTKRllRgAU0dd.JZ83EY2ErQgFz8K2H6hjxKDAZqXj0m4q8PU8bvQ_aG DoNBT8JRv7_XeT8rUnADZW7ErJifuyMKY9s98cYaGqCCj_UQ5T557Iu55Dlm TWm2oJnQIu0gz6tJn5qnHnc1upZAMj6VDkBFUkcK.xzAhHcMnUi3EBSP8Dux D7F0hREdAuQqGRrWsEEQM7w-- X-Yahoo-SMTP: xcjD0guswBAZaPPIbxpWwLcp9Unf Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: OpenOffice 4.1 build persistently fails on my FreeBSD-10-stable/AMD64 From: Pedro Giffuni In-Reply-To: <201408241839.s7OIdsd9055757@gw.catspoiler.org> Date: Sun, 24 Aug 2014 14:49:06 -0500 Message-Id: <10F07273-778A-4B42-B566-73B86BC906B7@freebsd.org> References: <201408241839.s7OIdsd9055757@gw.catspoiler.org> To: Don Lewis X-Mailer: Apple Mail (2.1878.6) Content-Type: text/plain; charset=iso-2022-jp Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.18-1 Cc: office@FreeBSD.org X-BeenThere: freebsd-office@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Office applications on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Aug 2014 19:50:18 -0000 Hi Don; Il giorno 24/ago/2014, alle ore 13:39, Don Lewis = ha scritto: > On 23 Aug, Pedro Giffuni wrote: >>=20 >> Il giorno 23/ago/2014, alle ore 20:32, Don Lewis >> ha scritto: >>=20 >>> On 23 Aug, Pedro Giffuni wrote: >>>>=20 >>>> On 08/23/14 13:51, Don Lewis wrote: >>>>> On 22 Aug, Pedro Giffuni wrote: >>>>>> FWIW, >>>>>>=20 >>>>>> AOO 4.1 is known to have bugs and AOO 4.1.1 will be released >>>>>> really soon to address them. The patch in PR 192545 unbreaks the >>>>>> AOO 4.1.0 build on FreeBSD 10 and >>>>> 11: >>>>>=20 >>>>> The patch in PR 192557 upgrades openoffice-devel to 4.1.1-RC3: >>>>> >>>>>=20 >>>>=20 >>>> The patch in PR 181044 fixes Boost so that it can be used as >>>> an external dependency for OpenOffice: >>>> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D181044 >>>=20 >>> Still no joy B-( >>>=20 >>> When I was first working on 4.1.0, I ran into the #include_next >>> problem and tried to work around it by adding >>> -DBOOST_TR1_DISABLE_INCLUDE_NEXT to CFLAGS. The errors still >>> occurred, but with different message text. >>>=20 >>> With this patch applied, I see the same thing as in my earlier >>> experiments: >>>=20 >>> In file included from /usr/local/include/boost/tr1/tr1/vector:16:0, >>> from >>> = /wrkdirs/usr/ports/editors/openoffice-devel/work/aoo-4.1.1/main/solver/411= /unxfbsdx.pro/inc/stl/vector:31, >>> from >>> = /wrkdirs/usr/ports/editors/openoffice-devel/work/aoo-4.1.1/main/xml2cmp/so= urce/finder/dependy.hxx:28, >>> from >>> = /wrkdirs/usr/ports/editors/openoffice-devel/work/aoo-4.1.1/main/xml2cmp/so= urce/finder/dependy.cxx:25: >>> /usr/local/include/boost/tr1/detail/config_all.hpp:163:41: fatal >>> error: ../4.7/utility: No such file or directory compilation >>> terminated. >>=20 >> Ugh=1B$B!D=1B(B this looks familiar :( >>=20 >> The problem is really messy: the original OpenOffice was developed in >> the dark ages of C++ libraries and used STLport as it=1B$B!G=1B(Bs = STL >> implementation. STLport doesn=1B$B!G=1B(Bt work with modern compilers = (like in >> MacOSX) so Boost is very handy because it has TR1 implementation = which >> can be very useful to complement older versions of libstdc++. With a >> good native STL library, AOO makes very little use, if any, of boost. >>=20 >> In order to be less disruptive, AOO has some wrappers for the STL >> libraries in main/stlport/systemstl and for some reason this works >> fine on for linux, Windows and MacOSX but it always gets those wrong >> on FreeBSD. >>=20 >> AOO appears to be the only package that exercises include_next = because >> the definition was wrong before my patch and no one had noticed. The >> explanation is here: >>=20 >> https://svn.boost.org/trac/boost/ticket/8944 >>=20 >> Perhaps the path may need adjusting for gcc4.7. Extra eyes are >> certainly welcome. >=20 > main/solver/411/unxfbsdx.pro/inc/stl/vector contains this: >=20 > #ifdef HAVE_STL_INCLUDE_PATH > // TODO: use computed include file name > #include_next > #elif defined(_MSC_VER) > #include <../../VC/include/vector> > #else // fall back to boost/tr1 > #include > #endif >=20 > which gets us into boost and it's emulation of #include_next. >=20 >=20 FWIW, this doesn=1B$B!G=1B(Bt work with libc++. I recall I had to define = HAVE_STL_INCLUDE_PATH manually to start the build with libc++. > If we were using our old gcc 4.2 in base, then we'd want to pick up = the > second of these: >=20 > %find /usr/include -name vector -print > /usr/include/c++/4.2/debug/vector > /usr/include/c++/4.2/vector >=20 > so your patch would work. >=20 >=20 OK. This makes sense: when I was working on this my main interest was to = keep building AOO with the base compiler in FreeBSD 9. > Using gcc 4.7, we want the last one of these: >=20 > %find /usr/local/lib/gcc47/include -name vector -print > /usr/local/lib/gcc47/include/c++/profile/vector > /usr/local/lib/gcc47/include/c++/debug/vector > /usr/local/lib/gcc47/include/c++/vector >=20 This is really ugly: includes under the lib directory are probably = against out heir(7) structure. The explanation is that it is not the base compiler, of course, and = having them in /usr/local/include may cause collisions with the compiler in base. > If I tweak the path in your patch to this: > +# define BOOST_TR1_STD_HEADER(name) <../c++/name> > I can successfully build OpenOffice with system boost. >=20 > It looks like this should also work with the gcc 4.6 port. >=20 > If you tweak your patch to distinguish between gcc 4.2 and later > versions and select the path accordingly, it should work for all = cases. >=20 I would really prefer not to tweak Boost for this. The truth is the = include_next trick is only meant to cover for deficiencies in the base compiler. The = real fix would be using libc++, but since we cant at this time, a valid = workaround would be accounting for that within AOO in the STLport wrapper (not sure if that will be something easy though). >=20 > Back to the original build failure ... for some reason unopkg.bin is > segfaulting when linked with the system libgraphite. I noticed that = the > silgraphite port picked up one of the patches silgraphite patches from > OpenOffice with some tweaks, but not the rest. >=20 The vast majority of the libgraphite patches in AOO were meant to = account for STLport, and were not needed in the port. I do see AOO has made at = least two important fixes that we should merge: http://svn.apache.org/viewvc/openoffice/trunk/main/graphite/?view=3Dlog All in all =1B$B!D=1B(B you could also turn off silgraphite and leave it = as an option: FreeType improved a lot the Adobe support lately and there are not many graphite enabled fonts anyways. Pedro. > GNU gdb 6.1.1 [FreeBSD] > Copyright 2004 Free Software Foundation, Inc. > GDB is free software, covered by the GNU General Public License, and = you are > welcome to change it and/or distribute copies of it under certain = conditions. > Type "show copying" to see the conditions. > There is absolutely no warranty for GDB. Type "show warranty" for = details. > This GDB was configured as "i386-marcel-freebsd"... > (gdb) run > Starting program: = /mnt2/tmp/mnt2/usr/ports/editors/openoffice-devel/work/aoo-4.1.1/main/inst= setoo_native/unxfbsdi.pro/Apache_OpenOffice/archive/install/en-US_witherro= r/Apache_OpenOffice_4.1.1_FreeBSD_install-arc_en-US/openoffice4/program/un= opkg.bin=20 > [New LWP 100780] > [New Thread 8a803080 (LWP 100780/unopkg.bin)] >=20 > Program received signal SIGSEGV, Segmentation fault. > [Switching to Thread 8a803080 (LWP 100780/unopkg.bin)] > 0x00000000 in ?? () > (gdb) tr > trace command requires an argument > (gdb) bt > #0 0x00000000 in ?? () > #1 0x88290bf4 in __dynamic_cast (src_ptr=3D0x8832fc40, = src_type=3D0x88326684,=20 > dst_type=3D0x88326540, src2dst=3D0) > at ../../.././../gcc-4.7.4/libstdc++-v3/libsupc++/dyncast.cc:61 > #2 0x882bf021 in std::has_facet > = (__loc=3D@0x8832f9b0) > at locale_classes.tcc:257 > #3 0x882b273a in std::basic_ios = >::_M_cache_locale (this=3D0x8832f944, __loc=3D@0x8832f9b0) at = basic_ios.tcc:160 > #4 0x882b27e9 in std::basic_ios >::init = ( > this=3D0x8832f944, __sb=3D0x8832f540) at basic_ios.tcc:133 > #5 0x882a42c3 in std::ios_base::Init::Init (this=3D0x8853264c) at = ostream:83 > #6 0x8832f944 in std::cout () from = /usr/local/lib/gcc47/libstdc++.so.6 > #7 0x8832f540 in __gnu_internal::buf_cin_sync () > from /usr/local/lib/gcc47/libstdc++.so.6 > Previous frame inner to this frame (corrupt stack?)