summaryrefslogtreecommitdiff
path: root/solenv
AgeCommit message (Collapse)AuthorFilesLines
2018-01-30Don't let PythonTest_solenv_python fail due to Emacs lock files in SRCDIRStephan Bergmann1-1/+3
Emacs has a habit of placing lock files next to files being edited, which are actually dangling symlinks not pointing at actual files, but where the symlink content itself encodes some information about who locked the file. When such a lock file happens to be present in the source tree during `make PythonTest_solenv_python`, the latter fails because shutil.copytree by default copies files pointed at by symlinks, instead of the symlinks themselves, and causes an error if that fails. An alternative fix would be to call shutil.copytree with symlinks=true (copy symlinks, not the files pointed at) or ignore_dangling_symlinks=true (don't fail if a dangling symlink can't be copied). But for now just don't copy any of those additional files that Emacs likes to place next to edited files (and which are also all ignored in our .gitignore). Change-Id: Ib731a5395fe8d40767878c17b1fb422b914bb329 Reviewed-on: https://gerrit.libreoffice.org/48898 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-01-24Natvis: update SfxItemSet visualizer (m_pItems is now unique_ptr)Mike Kaganski1-1/+1
Change-Id: I862f6399a9a065ef725211b44f77400927db9a8f Reviewed-on: https://gerrit.libreoffice.org/48496 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
2018-01-24Adapt solenv/flatpak-manifest.inStephan Bergmann1-3/+3
...to e1026e267b4b1b0b0bd645c6bc212d6fa71544f8 "pdfium: update to 3312" Change-Id: I319b00d13d8657849967e08e605d6428f30c5c2e
2018-01-24Globally disable -Wcast-function-type new with upcoming GCC 8Stephan Bergmann1-0/+7
...which unhelpfully even warns on reinterpret_cast, so causes failures like > [CXX] sal/osl/unx/signal.cxx > sal/osl/unx/signal.cxx: In function ‘bool onInitSignal()’: > sal/osl/unx/signal.cxx:267:50: error: cast between incompatible function types from ‘void (*)(int, siginfo_t*, void*)’ to ‘{anonymous}::Handler1’ {aka ‘void (*)(int)’} [-Werror=cast-function-type] > oact.sa_sigaction); > ^ And since all incompatible (but deliberate) casts between function types across our code base should already be written as reinterpret_cast, we shouldn't lose much by just disabling this new warning globally. Change-Id: If15e9606e8fdc676b61012e31d7369653951ceca Reviewed-on: https://gerrit.libreoffice.org/48431 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-01-23new loplugin: pointerboolNoel Grandin1-0/+1
look for possibly bogus implicit conversions to bool when passing (normally pointer) args to bool params. this plugin comes in the wake of a couple of bugs caused by refactoring, where some of the call sites were not currently updated. Of the changes, the following are real bugs: desktop/../dp_persmap.cxx StartInputFieldDlg in sw/../fldmgr.cxx which occurred as a result of commit 39d719a80d8c87856c84e3ecd569d45fa6f8a30e Date: Tue May 3 11:39:37 2016 +0200 tdf#99529 sw: don't pop up input field dialog before inserting field CSerializationURLEncoded::encode_and_append in forms/../serialization_urlencoded.cxx XclExpCFImpl::XclExpCFImpl in sc/../xecontent.cxx I have no idea how to properly fix this, just made a guess. SwDocTest::test64kPageDescs in sw/qa/core/uwriter.cxx which looks like a simple copy/paste error. Change-Id: I795ebd5ef485a1d36863dc27fe13832989f5a441 Reviewed-on: https://gerrit.libreoffice.org/48291 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-22gbuild: always compile as C++17 with MSVC 2017Michael Stahl1-0/+3
The current update MSVC 2017.5 supports fancy new C++ features, but unfortunately in its default C++14 mode it falls over and dies with an internal compiler error as soon as it sees the WeakImplHelper variadic template. In order to work around the ICE, build everything as C++17, which somehow doesn't crash. This causes loads of deprecation warnings about obsolete std::this and badly designed std::that, almost all of them from boost headers, which are well known for following every best practice in the C++ book. Liberally sprinkle macros around to suppress the warnings for now, like we already do with the other million warnings from boost headers. Change-Id: Ia6b6ef5e457b5fe3c8cfe361ba5da39376bb7c4c Reviewed-on: https://gerrit.libreoffice.org/48225 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2018-01-22update flatpak-manifestDavid Tardon1-3/+3
Change-Id: If97c2f8826cbbd83821d9211040f1857e1a1e17f
2018-01-22boost: upgrade to release 1.66.0Michael Stahl1-0/+5
This claims to support Visual Studio 2017.4, but not the current 2017.5. * remove boost.auto_link.patch; it does not apply; not sure why we need this if we can just define BOOST_ALL_NO_LIB (see commit 7f2e168421c3cd928a31a52a8b5afe97e931d3ba) * remove some hunks from clang-cl.patch.0 that look fixed upstream * add a global workaround for spurious GCC warning: oox/source/drawingml/shape.cxx:921:54: error: ‘oShadowColor.boost::optional_detail::tc_optional_base<int>::m_storage’ may be used uninitialized in this function [-Werror=maybe-uninitialized] aFormat.Color = *oShadowColor; Change-Id: I1eb1d8b66554a84a7d7269f1faaa98695fe2f501 Reviewed-on: https://gerrit.libreoffice.org/48187 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2018-01-19gbuild: disable gb_COLOR on WNT for nowMichael Stahl1-0/+3
The Cygwin terminal swallows colorful error messages, which is unhelpful. Change-Id: I2005994eb76fdba1dc49efc2988e38ac460d6724
2018-01-19new loplugin:emptyifNoel Grandin1-0/+1
Change-Id: I1092115a0ceb3a5e6680a4b724b129f98a892c42 Reviewed-on: https://gerrit.libreoffice.org/48128 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-19Fix typosAndrea Gelmini1-1/+1
Change-Id: Icadf5cb88024b8889d49dc9c5210d0de8deaed3b Reviewed-on: https://gerrit.libreoffice.org/48172 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-18android: use unified headers and llvm-c++ STL (x86) with NDK 16Christian Lohmaier2-7/+17
gnustl (and others) are to be removed in future versions of the ndk also bump gradle and build-tools to current versions along with it arm unfortunately crashes with llvm-c++, so keep with gnustl for now/fix that later Change-Id: Ic794c3293b599b77ec48096bf3283a99c09cbb79 Reviewed-on: https://gerrit.libreoffice.org/45163 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2018-01-18clang-format: allow just listing formatted filesMiklos Vajna1-2/+16
Without running clang-format on them. Also format one file at a time, so we don't run into command line length limits as the number of formatted files grows. Change-Id: Ie559d566db784e04965678f056dcb81cefe95378 Reviewed-on: https://gerrit.libreoffice.org/48085 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-01-14Fix typosAndrea Gelmini1-1/+1
Change-Id: Icc5fc590a6a90e30afa5f61028d4dd0279fbe120 Reviewed-on: https://gerrit.libreoffice.org/47861 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2018-01-14Save full file path to pot filesGabor Kelemen2-2/+2
As requested here: http://nabble.documentfoundation.org/libreoffice-l10n-Pootle-source-file-paths-not-available-anymore-td4229127.html This adds the full source file path in case of .hrc and .ui files to the generated pot, relatie to srcdir. So instead of personalization.hrc:31 we can have cui/inc/personalization.hrc:31 for better context for translators. Since this is only in comment this will not change the translated status of strings. TODO: the other file formats we use are not affected by this. Change-Id: Id436d66698c93e07c46bf9c20601c5b480eadd0b Reviewed-on: https://gerrit.libreoffice.org/46591 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Andras Timar <andras.timar@collabora.com>
2018-01-12Enable loplugin:cstylecast for some more casesStephan Bergmann1-0/+1
...mostly of C-style casts among arithmetic types, and automatically rewrite those into either static_cast or a functional cast (which should have identical semantics, but where the latter probably looks better for simple cases like casting a literal to a specific type, as in "sal_Int32(0)" vs. "static_cast<sal_Int32>(0)"). The main benefit of reducing the amount of C-style casts across the code base further is so that other plugins (that have not been taught about the complex semantics of C-style cast) can pick those up (cf. the various recent "loplugin:redundantcast" commits, which address those findings after this improved loplugin:cstylecast has been run). Also, I found some places where a C-style cast has probably been applied only to the first part of a larger expression in error (because it's easy to forget parentheses in cases like "(sal_uInt16)VOPT_CLIPMARKS+1"); I'll follow up on those individually. The improved loplugin:cstylecast is careful to output either "(performs: static_cast)" or "(performs: functional cast)", so that compilerplugins/clang/test/cstylecast.cxx can check that the plugin would automatically rewrite to one or the other form. To allow fully-automatic rewriting, this also required loplugin:unnecessaryparen to become a rewriting plugin, at least for the parens-around-cast case (where "((foo)bar)" first gets rewritten to "(static_cast<foo>(bar))", then to "static_cast<foo>(bar)". Rewriting could probably be added to other cases of loplugin:unnecessaryparen in the future, too. (The final version of this patch would even have been able to cope with 361dd2576a09fbda83f3ce9a26ecb590c38f74e3 "Replace some C-style casts in ugly macros with static_cast", so that manual change would not have been necessary after all.) Change-Id: Icd7e319cc38eb58262fcbf7643d177ac9ea0220a Reviewed-on: https://gerrit.libreoffice.org/47798 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-01-12Support `make SdiTarget_...`Stephan Bergmann1-0/+1
Change-Id: I23dc4511a6f9f962adc8436ceb1a5b24823fb8e5 Reviewed-on: https://gerrit.libreoffice.org/47788 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-01-10gbuild: print a better error message when adding non-existing ModuleMichael Stahl1-1/+6
A confusing message "Corrupted module target stack!" is printed because: "If an included makefile cannot be found in any of these directories, a warning message is generated, but it is not an immediately fatal error; processing of the makefile containing the include continues. Once it has finished reading makefiles, make will try to remake any that are out of date or don’t exist." Change-Id: Ia728c0283885fe839dbf8dd8ae2a885230f23836 Reviewed-on: https://gerrit.libreoffice.org/47701 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Jenkins <ci@libreoffice.org>
2018-01-09upload libpagemaker 0.0.4David Tardon1-3/+3
Change-Id: Idc4b7eaa3331ee3831f7d27ca66663e23c30b8c9 Reviewed-on: https://gerrit.libreoffice.org/47615 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com>
2018-01-08Let flatpak-builder build .Debug extensionStephan Bergmann2-2/+2
Includes a revert of 58891d589bd8da700f135b098dd50833277c65dc "Add distro-pack- install-strip target to be used by dev-tools' flatpak/build.sh". Change-Id: Ie2ba18bc13471b46e8d5f41868bae5aee17ff25f Reviewed-on: https://gerrit.libreoffice.org/47599 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-01-08gcc-wrappers: always pass -debug to linkerMichael Stahl1-1/+2
... like gbuild does; this causes a PDB file to be created, which is required by BinScope. Stops complaints about firebird's DLLs, which are apparently the only DLLs linked with gcc-wrapper. Change-Id: Ibe0e8053e0556748b1562b5f50f08480b2f2f89b
2018-01-08gcc-wrappers: recognise -ggdb.* in addition to -g as debug flagMichael Stahl1-1/+1
Firebird uses -ggdb. This causes it to have 2 PDB files, however this isn't sufficient to make BinScope happy, more investigation needed. Change-Id: I5286964586eaffea36790ab7a7ca2df75d85f068
2018-01-08gbuild: MSVC: invoke MSASM with /safesehMichael Stahl1-1/+1
BinScope complains that the sblo.dll lacks SAFESEH flag. Change-Id: If2b4b6592eac37542c3e2745d90a8e432b8da2e2
2018-01-06upload libabw 0.1.2David Tardon1-3/+3
Change-Id: I972ff9e0dbb73f6a38c886e1acd03cc4d62da2ec Reviewed-on: https://gerrit.libreoffice.org/47251 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com>
2018-01-05upload libe-book 0.1.3David Tardon1-3/+3
Change-Id: I8862e7f4d2dcb007295028b9ec7be04e58ebafd3 Reviewed-on: https://gerrit.libreoffice.org/47264 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com>
2018-01-05remove dead eeitemid.hxxNoel Grandin1-1/+0
and inline the couple of constants still in use from it Change-Id: Icb9f5690b5649140bc0503a8917e6a0f764e3d9c Reviewed-on: https://gerrit.libreoffice.org/47404 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-04sw: move some globals in fetab.cxx into SwFEShellMichael Stahl1-1/+0
It looks like the main point of these being globals is so that they can be cleared from various places when tables or table frames are destroyed. Add a SwDoc parameter to ClearFEShellTabCols() and just iterate over all shells. Change-Id: I75ad6b695ee1bfa76b9a05c606b07a3574c70ac4
2018-01-04basegfx: extract svg path import/export test to own fileTomaž Vajngerl1-0/+1
Change-Id: If9925540feb54e5a101c76f8d4cebaa305ac4c75 Reviewed-on: https://gerrit.libreoffice.org/47299 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-01-04remove SfxUsrAnyItem typedefNoel Grandin1-1/+1
and rename SfxUsrAnyItem class to SfxUnoAnyItem, the choice being made by leaving the most popular one behind Change-Id: If3818ee0966a50e3036d7e2db951910b6282c91f Reviewed-on: https://gerrit.libreoffice.org/47313 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-01-03Turn on clang-format for these filesMiklos Vajna1-5/+0
I (tried to) keep these files consistent locally with astyle in the past, switching to clang-format makes sure that the recent problem with introducing inconsistencies with automatic loplugin rewrites doesn't happen again. Change-Id: If49c96b6e9e6ed50beb69c70e37125dff5607f76 Reviewed-on: https://gerrit.libreoffice.org/47332 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-01-03Add JVM support to FlatpakStephan Bergmann1-0/+113
...fixing <https://github.com/flathub/org.libreoffice.LibreOffice/issues/5> "Add JRE-based components". It appeared to be easiest to install the Ant build-time dependency to /run/build/libreoffice/ant, instead of making it into a flatpak-builder module of its own. (The sha512 is as given at <http://ant.apache.org/bindownload.cgi>.) To avoid further dependencies, configure --without-export-validation and --without-junit, only affecting build-time checks (and the amount of checks thus affected by a plain `make` should be small). Change-Id: I5b67c37f168533f9dc7ade11c7c4e2c42814b942 Reviewed-on: https://gerrit.libreoffice.org/47322 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-01-03Adapt solenv/flatpak-manifest.in to recent download.lst changesStephan Bergmann1-18/+60
...and recently added fonts Change-Id: I2eedcb1b8af28b15b93c912bd0cc2d08d5c4db0d Reviewed-on: https://gerrit.libreoffice.org/47321 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-01-03solenv: fix typo in native-code.pyMiklos Vajna1-2/+2
Change-Id: I191c0586a5bf9b3be1811ff783cb80dd13638c53
2018-01-02ofz#4864 SvgTools::create required via html importCaolán McNamara1-1/+1
Change-Id: I2c7378e5226c1ce45a89b97ddce93bc0e6e96a33 Reviewed-on: https://gerrit.libreoffice.org/47257 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2017-12-24Improve Natvis display of SwNodeMike Kaganski1-17/+31
Change-Id: Ib1d4b8ed69ab60e9d7fccc6627051500d62c4a49 Reviewed-on: https://gerrit.libreoffice.org/47049 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
2017-12-21solenv: support PYTHON_TEST_NAME for python testsMiklos Vajna4-1/+40
This is similar to CPPUNIT_TEST_NAME for CppunitTests, i.e. allows running a single module/class/method only, instead of all modules added by gb_PythonTest_add_modules. Example: make PythonTest_sw_python PYTHON_TEST_NAME="text_portion_enumeration_test.TextPortionEnumerationTest.test_empty2" Change-Id: Ibed5729bc29a5112216bce211455d6c6a0837b30 Reviewed-on: https://gerrit.libreoffice.org/46907 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2017-12-21new loplugin: convertlongNoel Grandin2-4/+1
merge the droplong and convertuintptr into one new plugin. Limit the analysis to looking at var decl's, since that seems to be safest proposition, even if that too needs some careful analysis. Change-Id: Id005baaf05cfb157ce44a06a1c81f08559a07d1f Reviewed-on: https://gerrit.libreoffice.org/46851 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-20inline typedefs in connectivity/StdTypeDefsNoel Grandin1-1/+0
Change-Id: I614833ed2418ff99057c7d496ddb64f06e8395db Reviewed-on: https://gerrit.libreoffice.org/46809 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-12-18tdf#108580: integrate vc_redist.exe into MSIMike Kaganski1-1/+1
... in InstallUISequense. Use --with-vcredist-dir to point to a directory with vc_redist.x64.exe and/or vc_redist.x86.exe. Use --without-vcredist-dir (or --with-vcredist-dir=no) if you don't want to ship it as part of installer and want to silence the configure warning. VCRedist 2015 version 14.0.24215.1 is available at https://www.microsoft.com/en-us/download/details.aspx?id=53840 Since VisualStudio 2015, VC redist merge module that we used before started to work differently: it installs the UCRT only on WinXP, but not on later OSes (Vista to 8.1) which may lack the UCRT (Win10 has it out of the box). The merge module only installs VCRuntime on those systems, which still leaves us with "api-ms-*.dll is missing" problem. (https://blogs.msdn.microsoft.com/vcblog/2015/03/03/introducing-the-universal-crt/ gives more information on VCRedist refactoring background.) Since commit 71d9a61302e65fe091cf70c13fa72b3df09b7e3a, we use a workaround described at the page mentioned above as "App-local deployment of the Universal CRT". We just copy all UCRT DLLs to LibreOffice/program. This has a drawback though, that our UCRT is not updated by Windows Update, so users would rely on LibreOffice updates in case of some vulnerabilities in UCRT (and they could even not realize they have that problem). MS recommends to install UCRT using EXEs they provide from their site. The EXEs install both VCRuntimes and UCRTs, along with required patches, for all Windows versions (Windows XP through Windows 10, where they only install VCRuntimes); the installed libraries are managed by system's update mechanism. But those EXEs cannot be used in MSI custom actions inside InstallExecuteSequence, because they use MSI themselves. So this patch integrates the vc_redist.xXX.exe into MSI binary table, and uses custom action to run the EXE after ExecuteAction in InstallUISequence. This will show the user a VCRedist install window after the main LibreOffice installation finishes; no user interaction is required (except for one additional UAC request), and errors are ignored. Since this installation takes care of both VCRuntime and UCRT, we can ultimately drop both the app-local workaround, and vcredist merge module (so VCRuntime would also be updated by system). The former is done here: this reverts commit 71d9a61302e65fe091cf70c13fa72b3df09b7e3a. This approach has its drawback: if one wants to use unattended installation (without UI; one example is deployment using ActiveDirectory GPO), then InstallUISequence is not run, and so VCRedist isn't installed. In this case, one should install VCRedist separately. Supposedly this should not be huge problem, because this is the case for many existing applications that need separate VCRedist deployment in these scenarios, and unattended installation is advanced stuff that requires prepared user. A notice would be required in release notes and FAQ, though. Change-Id: Ia6a16be60af8a08f41ea7c3dbd457d8f89006006 Reviewed-on: https://gerrit.libreoffice.org/46356 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
2017-12-15clang-format: restore lost warning on touching formatted file without checkMiklos Vajna1-11/+14
Consistently only assign something to $clang_format if it's a good version, and also consistently return undef if we found no good version. Change-Id: Iadbbb56a5c15dfaeec5c80e3cc8fcc78b787c04b Reviewed-on: https://gerrit.libreoffice.org/46489 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2017-12-15once off loplugin: unusedindexNoel Grandin1-0/+1
Change-Id: Ifdf5da1f014c4f130eafed475c6781c029d54f1d
2017-12-14Add wrongly formatted new file to blacklistStephan Bergmann1-0/+1
Change-Id: I56963d2eb273fdb0db375af54186e8a3b01b06a1
2017-12-13clang-format: ignore not staged hunksMiklos Vajna1-2/+10
09:28 <@sberg> vmiklos, I think I ran into a scenario last night where I had both `git add`-ed and non-added changes in a non-blacklisted file, and the non-added changes violated clang-format (and the added ones did not), and the commit hook complained So make sure we validate the index version, not the filesystem one. (And modify a formatted file to trigger CI validation of the hook change itself.) Change-Id: I6431b35ac50dd03741104b5709c5195d6ff28632 Reviewed-on: https://gerrit.libreoffice.org/46368 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2017-12-12CppunitTest_xmlsecurity_signing failed in sanitizer buildsStephan Bergmann1-1/+1
...because external/gpgmepp spawns /usr/bin/gpgconf (and later on /usr/bin/ggp2, /usr/bin/gpgsm) which all depend on libgpg-error.so.0, so due to CppunitTest's LD_LIBRARY_PATH will pick up instdir/program/libgpg-error.so.0, which fails due to > /usr/bin/gpgconf: symbol lookup error: /data/sbergman/lo-san/core/instdir/program/libgpg-error.so.0: undefined symbol: __asan_option_detect_stack_use_after_return The easiest fix appears to be, when running sanitizers on Linux, to hack gpgmepp's _gpgme_io_spawn to set LD_LIBRARY_PATH back to its original state. (When it was originally unset, it will now be set but null, but that should not make a difference.) This requires EXTRA_ENV_VARS to be set earlier in CppunitTest.mk, so setting LIBO_LD_PATH doesn't use the LD_LIBRARY_PATH value set in gb_CppunitTest_CPPTESTPRECOMMAND. The backtrace of the first, originally failing call to _gpgme_io_spawn during CppunitTest_xmlsecurity_signing: > #0 0x00007fffe1f354dc in _gpgme_io_spawn (path=0x1 <error: Cannot access memory at address 0x1>, argv=0x7ffff2fbd4e0, flags=0, fd_list=0x9, atfork=0x4e, atforkvalue=0x7ffff2fbd4e0, r_pid=0x7ffff2fbd4e0) at posix-io.c:433 > #1 0x00007fffe1f41971 in read_gpgconf_dirs (pgmname=0x6110002f8e00 "/usr/bin/gpgconf", components=0) at dirinfo.c:206 > #2 0x00007fffe1f3fa29 in get_gpgconf_item (what=12) at dirinfo.c:284 > #3 0x00007fffe1f4073e in _gpgme_get_default_gpg_name () at dirinfo.c:370 > #4 0x00007fffe1e87093 in engine_get_file_name (proto=GPGME_PROTOCOL_OpenPGP) at engine.c:79 > #5 0x00007fffe1e84e89 in gpgme_get_engine_info (info=0x7ffff2a06160) at engine.c:230 > #6 0x00007fffe1e845ef in gpgme_engine_check_version (proto=GPGME_PROTOCOL_OpenPGP) at engine.c:144 > #7 0x00007fffe634e7d9 in GpgME::checkEngine(GpgME::Protocol) (proto=GpgME::OpenPGP) at context.cpp:1610 > #8 0x00007fff8df3fd49 in SecurityEnvironmentGpg::SecurityEnvironmentGpg() (this=0x6060005825c0) at xmlsecurity/source/gpg/SecurityEnvironment.cxx:30 > #9 0x00007fff8df5755e in SEInitializerGpg::createSecurityContext(rtl::OUString const&) (this=0x606000582560) at xmlsecurity/source/gpg/SEInitializer.cxx:45 > #10 0x00007fff8df57bb3 in non-virtual thunk to SEInitializerGpg::createSecurityContext(rtl::OUString const&) () at include/rtl/stringutils.hxx:170 > #11 0x00007fffab66de90 in DocumentSignatureManager::init() (this=0x7ffff2fbb020) at xmlsecurity/source/helper/documentsignaturemanager.cxx:78 > #12 0x00007fffab498504 in DocumentDigitalSignatures::ImplVerifySignatures(com::sun::star::uno::Reference<com::sun::star::embed::XStorage> const&, com::sun::star::uno::Reference<com::sun::star::io::XInputStream> const&, DocumentSignatureMode) (this=0x6080001aaf20, rxStorage=uno::Reference to (OStorage *) 0x60d0003a4c48, xSignStream=empty uno::Reference, eMode=DocumentSignatureMode::Content) at xmlsecurity/source/component/documentdigitalsignatures.cxx:264 > #13 0x00007fffab497f8b in DocumentDigitalSignatures::verifyDocumentContentSignatures(com::sun::star::uno::Reference<com::sun::star::embed::XStorage> const&, com::sun::star::uno::Reference<com::sun::star::io::XInputStream> const&) (this=0x6080001aaf20, rxStorage=uno::Reference to (OStorage *) 0x60d0003a4c48, xSignInStream=empty uno::Reference) at xmlsecurity/source/component/documentdigitalsignatures.cxx:127 > #14 0x00007fffab49c35b in non-virtual thunk to DocumentDigitalSignatures::verifyDocumentContentSignatures(com::sun::star::uno::Reference<com::sun::star::embed::XStorage> const&, com::sun::star::uno::Reference<com::sun::star::io::XInputStream> const&) () at include/cppu/unotype.hxx:136 > #15 0x00007fffafc062a3 in SfxObjectShell::ImplAnalyzeSignature(bool, com::sun::star::uno::Reference<com::sun::star::security::XDocumentDigitalSignatures> const&) (this=0x61100021c7c0, bScriptingContent=false, xSigner=empty uno::Reference) at sfx2/source/doc/objserv.cxx:1293 > #16 0x00007fffafc074b1 in SfxObjectShell::ImplGetSignatureState(bool) (this=0x61100021c7c0, bScriptingContent=false) at sfx2/source/doc/objserv.cxx:1322 > #17 0x00007fffafc0383d in SfxObjectShell::GetDocumentSignatureState() (this=0x61100021c7c0) at sfx2/source/doc/objserv.cxx:1485 > #18 0x00007fffafbb323c in SfxObjectShell::CheckForBrokenDocSignatures_Impl() (this=0x61100021c7c0) at sfx2/source/doc/objmisc.cxx:981 > #19 0x00007fffafbb2da4 in SfxObjectShell::CheckSecurityOnLoading_Impl() (this=0x61100021c7c0) at sfx2/source/doc/objmisc.cxx:931 > #20 0x00007fffafbb95cf in SfxObjectShell::FinishedLoading(SfxLoadedFlags) (this=0x61100021c7c0, nFlags=SfxLoadedFlags::ALL) at sfx2/source/doc/objmisc.cxx:1079 > #21 0x00007fff716a9185 in SwDocShell::LoadingFinished() (this=0x61100021c7c0) at sw/source/uibase/app/docsh.cxx:1153 > #22 0x00007fff71759ada in SwDocShell::Load(SfxMedium&) (this=0x61100021c7c0, rMedium=...) at sw/source/uibase/app/docshini.cxx:581 > #23 0x00007fffafc2bd9a in SfxObjectShell::LoadOwnFormat(SfxMedium&) (this=0x61100021c7c0, rMedium=...) at sfx2/source/doc/objstor.cxx:2971 > #24 0x00007fffafc3128c in SfxObjectShell::DoLoad(SfxMedium*) (this=0x61100021c7c0, pMed=0x60300083dac0) at sfx2/source/doc/objstor.cxx:714 > #25 0x00007fffafdd88d8 in SfxBaseModel::load(com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) (this=0x6190000fb0b0, seqArguments=uno::Sequence of length 13 = {...}) at sfx2/source/doc/sfxbasemodel.cxx:1788 > #26 0x00007fffb049a98a in (anonymous namespace)::SfxFrameLoader_Impl::load(com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&, com::sun::star::uno::Reference<com::sun::star::frame::XFrame> const&) (this=0x6060004aaec0, rArgs=uno::Sequence of length 11 = {...}, _rTargetFrame=uno::Reference to ((anonymous namespace)::Frame *) 0x6160000c63f0) at sfx2/source/view/frmload.cxx:693 > #27 0x00007fff82d6a7ee in framework::LoadEnv::impl_loadContent() (this=0x7ffff2fe3040) at framework/source/loadenv/loadenv.cxx:1105 > #28 0x00007fff82d5aa6b in framework::LoadEnv::startLoading() (this=0x7ffff2fe3040) at framework/source/loadenv/loadenv.cxx:374 > #29 0x00007fff82d56633 in framework::LoadEnv::loadComponentFromURL(com::sun::star::uno::Reference<com::sun::star::frame::XComponentLoader> const&, com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&, rtl::OUString const&, rtl::OUString const&, int, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) (xLoader=uno::Reference to (framework::Desktop *) 0x6160000153f8, xContext=uno::Reference to (cppu::ComponentContext *) 0x611000002b10, sURL="file:///xmlsecurity/qa/unit/signing/data/goodGPG.odt", sTarget="_default", nFlags=0, lArgs=uno::Sequence of length 2 = {...}) at framework/source/loadenv/loadenv.cxx:160 > #30 0x00007fff82ec93f0 in framework::Desktop::loadComponentFromURL(rtl::OUString const&, rtl::OUString const&, int, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) (this=0x616000015380, sURL="file:///xmlsecurity/qa/unit/signing/data/goodGPG.odt", sTargetFrameName="_default", nSearchFlags=0, lArguments=uno::Sequence of length 2 = {...}) at framework/source/services/desktop.cxx:618 > #31 0x00007fff82ec95eb in non-virtual thunk to framework::Desktop::loadComponentFromURL(rtl::OUString const&, rtl::OUString const&, int, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) () at include/rtl/stringutils.hxx:170 > #32 0x00007fffabe3097d in unotest::MacrosTest::loadFromDesktop(rtl::OUString const&, rtl::OUString const&, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) (this=0x60c000035e48, rURL="file:///xmlsecurity/qa/unit/signing/data/goodGPG.odt", rDocService="com.sun.star.text.TextDocument", rExtraArgs=empty uno::Sequence) at unotest/source/cpp/macros_test.cxx:50 > #33 0x00007fffb2ba9d2a in SigningTest::createDoc(rtl::OUString const&) (this=0x60c000035e00, rURL="file:///xmlsecurity/qa/unit/signing/data/goodGPG.odt") at xmlsecurity/qa/unit/signing/signing.cxx:204 > #34 0x00007fffb2bd1532 in SigningTest::testODFGoodGPG() (this=0x60c000035e00) at xmlsecurity/qa/unit/signing/signing.cxx:690 > #35 0x00007fffb2c304fd in std::__invoke_impl<void, void (SigningTest::*&)(), SigningTest*&>(std::__invoke_memfun_deref, void (SigningTest::*&)(), SigningTest*&) (__f=@0x6030001f0480: (void (SigningTest::*)(SigningTest * const)) 0x7fffb2bd0d80 <SigningTest::testODFGoodGPG()>, __t=@0x6030001f0490: 0x60c000035e00) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/bits/invoke.h:73 > #36 0x00007fffb2c300e0 in std::__invoke<void (SigningTest::*&)(), SigningTest*&>(void (SigningTest::*&)(), SigningTest*&) (__fn=@0x6030001f0480: (void (SigningTest::*)(SigningTest * const)) 0x7fffb2bd0d80 <SigningTest::testODFGoodGPG()>, __args=@0x6030001f0490: 0x60c000035e00) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/bits/invoke.h:95 > #37 0x00007fffb2c2ff2f in std::_Bind<void (SigningTest::*(SigningTest*))()>::__call<void, , 0ul>(std::tuple<>&&, std::_Index_tuple<0ul>) (this=0x6030001f0480, __args=...) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/functional:467 > #38 0x00007fffb2c2fb23 in std::_Bind<void (SigningTest::*(SigningTest*))()>::operator()<, void>() (this=0x6030001f0480) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/functional:549 > #39 0x00007fffb2c2e8d1 in std::_Function_handler<void (), std::_Bind<void (SigningTest::*(SigningTest*))()> >::_M_invoke(std::_Any_data const&) (__functor=...) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/bits/std_function.h:316 > #40 0x00007fffb2c30b1c in std::function<void ()>::operator()() const (this=0x608000083660) at /usr/lib/gcc/x86_64-redhat-linux/7/../../../../include/c++/7/bits/std_function.h:706 > #41 0x00007fffb2c2db41 in CppUnit::TestCaller<SigningTest>::runTest() (this=0x608000083620) at workdir/UnpackedTarball/cppunit/include/cppunit/TestCaller.h:175 > #42 0x00007ffff78fc159 in CppUnit::TestCaseMethodFunctor::operator()() const (this=0x7ffff2e9c0d0) at TestCase.cpp:32 > #43 0x00007fffdc3cc8e3 in (anonymous namespace)::Protector::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x602000019910, functor=...) at test/source/vclbootstrapprotector.cxx:48 > #44 0x00007ffff78ccf96 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const (this=0x6030002189e0) at ProtectorChain.cpp:20 > #45 0x00007fffe8938ab3 in (anonymous namespace)::Prot::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x6020000003f0, functor=...) at unotest/source/cpp/unobootstrapprotector/unobootstrapprotector.cxx:89 > #46 0x00007ffff78ccf96 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const (this=0x603000218a10) at ProtectorChain.cpp:20 > #47 0x00007fffebc1e492 in (anonymous namespace)::Prot::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x602000000250, functor=..., context=...) at unotest/source/cpp/unoexceptionprotector/unoexceptionprotector.cxx:63 > #48 0x00007ffff78ccf96 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const (this=0x603000218a40) at ProtectorChain.cpp:20 > #49 0x00007ffff7863084 in CppUnit::DefaultProtector::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x602000000150, functor=..., context=...) at DefaultProtector.cpp:15 > #50 0x00007ffff78ccf96 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const (this=0x603000218a70) at ProtectorChain.cpp:20 > #51 0x00007ffff78c68f5 in CppUnit::ProtectorChain::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) (this=0x60b000000510, functor=..., context=...) at ProtectorChain.cpp:86 > #52 0x00007ffff795e259 in CppUnit::TestResult::protect(CppUnit::Functor const&, CppUnit::Test*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) (this=0x7ffff2f000a0, functor=..., test=0x608000083620, shortDescription="") at TestResult.cpp:182 > #53 0x00007ffff78fa785 in CppUnit::TestCase::run(CppUnit::TestResult*) (this=0x608000083620, result=0x7ffff2f000a0) at TestCase.cpp:91 > #54 0x00007ffff798c2fe in CppUnit::TestRunner::WrappingSuite::run(CppUnit::TestResult*) (this=0x608000081820, result=0x7ffff2f000a0) at TestRunner.cpp:47 > #55 0x00007ffff795ccdf in CppUnit::TestResult::runTest(CppUnit::Test*) (this=0x7ffff2f000a0, test=0x608000081820) at TestResult.cpp:149 > #56 0x00007ffff798d23f in CppUnit::TestRunner::run(CppUnit::TestResult&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) (this=0x7ffff2f4db00, controller=..., testPath="") at TestRunner.cpp:96 > #57 0x000000000052e3a9 in (anonymous namespace)::ProtectedFixtureFunctor::run() const (this=0x7ffff2f00350) at sal/cppunittester/cppunittester.cxx:319 > #58 0x000000000052ae38 in sal_main() () at sal/cppunittester/cppunittester.cxx:469 > #59 0x0000000000529e2c in main(int, char**) (argc=23, argv=0x7fffffff2798) at sal/cppunittester/cppunittester.cxx:376 Change-Id: I386a3b316c78344c2449568894c0f03ba39b1bf0 Reviewed-on: https://gerrit.libreoffice.org/46249 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-12-08New --enable-compiler-plugins=debug modeStephan Bergmann2-0/+6
...to enable debug-only code in the plugins. Some situations in the plugin code should never happen, yet must not by default report errors or trigger assertions, as some newly written LO code could trigger them nevertheless (in which case the plugin code will likely need to be adapted, to cater for these presumed-impossible situations). Such code can now be included in the plugins behind an if(isDebugMode()) guard, and can explicitly be enabled with --enable-compiler-plugins=debug. I deliberately made this a runtime rather than a compile time option (using some #ifdef guards in the plugin code, say), as it IMO keeps the code more readable, and also allows overridding COMPILER_PLUGINS_DEBUG=... on the make command line. Change-Id: Iea4f0c2783ad968a0de097fa710b3be1a248de73 Reviewed-on: https://gerrit.libreoffice.org/46096 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-12-07allow to build only HTML helpDavid Tardon2-1/+42
Change-Id: I4debf079be228e5ce5fae5f1a153f78800407a59
2017-12-07solenv: add clang-format documentationMiklos Vajna2-2/+35
Change-Id: Ia1231fb16c351cf957bafaf07ed0ff0e4ff896dd Reviewed-on: https://gerrit.libreoffice.org/46008 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2017-12-07use 3-char announce id as elsewhere in gbuildDavid Tardon1-1/+1
Change-Id: I2f8f1d6876e7305bec45038ada402aa423e59ad8
2017-12-04Honor GTK theming in LO flatpakStephan Bergmann1-0/+2
...according to alexlarson, for now (until "eventually we'll have a sane dconf in the sandbox") apps need to specify --filesystem=xdg-run/dconf, --filesystem=~/.config/dconf:ro, --talk-name=ca.desrt.dconf, --env=DCONF_USER_CONFIG_DIR=.config/dconf (where the first two are irrelevant for LO due to its --filesystem=host). This fixes <https://github.com/flathub/org.libreoffice.LibreOffice/issues/4> "Libreoffice flatpak is not respecting user theme". Change-Id: If5ed33e1b524bfa877b89f052c6067398b5600a3
2017-12-04Adapt solenv/flatpak-manifest.in to recent download.lst changesStephan Bergmann1-6/+6
Change-Id: I74845d4cdab0f4769cb4970db12f3dfa09037c41