...as emsdk 5.0.3 deprecated the predefined EMSCRIPTEN macro (see
<https://github.com/emscripten-core/emscripten/commit/506052bd8b4e23ded7f2351c62ca3b24d40c8cf3>
"Warn about usage of deprecated EMSCRIPTEN macro. NFC (#26381)"), causing
failures like
> In file included from static/source/unoembindhelpers/PrimaryBindings.cxx:29:
> In file included from include/sfx2/viewsh.hxx:35:
> In file included from include/editeng/outliner.hxx:32:
> In file included from include/tools/color.hxx:26:
> include/osl/endian.h:66:15: error: macro 'EMSCRIPTEN' has been marked as deprecated: use __EMSCRIPTEN__ instead [-Werror,-Wdeprecated-pragma]
> 66 | #elif defined EMSCRIPTEN
> | ^
> /home/sberg/emsdk/5.0.4/emsdk/emscripten/main/cache/sysroot/include/emscripten/emscripten.h:35:66: note: macro marked 'deprecated' here
> 35 | #pragma clang deprecated(EMSCRIPTEN, "use __EMSCRIPTEN__ instead")
> | ^
To avoid confusion, also suppress the -D$(OS) in
solenv/gbuild/platform/unxgcc.mk that would unnecessarily keep defining
EMSCRIPTEN.
Change-Id: Ic1f187cf1c6417cd95d4092e9cea01a665bd1b2f
Reviewed-on: https://gerrit.collaboraoffice.com/c/core/+/34
Reviewed-by: Michael Stahl <michael.stahl@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 50291c2ed83bdb49bb827a4a12905d94b8c42035)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/205167
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
> In file included from idl/source/cmptools/lex.cxx:22:
> In member function ‘SvToken& SvToken::operator=(const SvToken&)’,
> inlined from ‘void SvTokenStream::FillTokenList()’ at idl/source/cmptools/lex.cxx:92:35:
> idl/inc/lex.hxx:35:7: error: ‘<anonymous>.SvToken::<anonymous>’ may be used uninitialized [-Werror=maybe-uninitialized]
> 35 | class SvToken
> | ^~~~~~~
> idl/source/cmptools/lex.cxx: In member function ‘void SvTokenStream::FillTokenList()’:
> idl/source/cmptools/lex.cxx:92:35: note: ‘<anonymous>’ declared here
> 92 | *pToken = SvToken();
> | ^
> In member function ‘SvToken& SvToken::operator=(const SvToken&)’,
> inlined from ‘void SvTokenStream::FillTokenList()’ at idl/source/cmptools/lex.cxx:101:31:
> idl/inc/lex.hxx:35:7: error: ‘<anonymous>.SvToken::<anonymous>’ may be used uninitialized [-Werror=maybe-uninitialized]
> 35 | class SvToken
> | ^~~~~~~
> idl/source/cmptools/lex.cxx: In member function ‘void SvTokenStream::FillTokenList()’:
> idl/source/cmptools/lex.cxx:101:31: note: ‘<anonymous>’ declared here
> 101 | *pToken = SvToken();
> | ^
seen in optimizing LO builds using at least GCC 12
(<https://ci.libreoffice.org/job/gerrit_linux_gcc_release/192633/>) and GCC 15
(locally, gcc-15.1.1-2.fc42.x86_64) after upcoming
<https://gerrit.libreoffice.org/c/core/+/188236> "Make O[U]String default ctors
constexpr".
(And without adding the additional braces in the second code block, at least GCC
15 would emit an odd
> idl/source/cmptools/lex.cxx: In member function ‘void SvTokenStream::FillTokenList()’:
> idl/source/cmptools/lex.cxx:116:9: error: ‘else’ without a previous ‘if’
> 116 | else if( pToken->IsEof() )
> | ^~~~
)
Change-Id: I171c746ea3f6035bc737b4bcd636dd063dd9186e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188265
Reviewed-by: Stephan Bergmann <stephan.bergmann@collabora.com>
Tested-by: Jenkins
after const clean up of the Slot* argument
objdump -t instdir/program/libsclo.so |grep -v data.rel.ro|grep \\\.data|c++filt|grep -v s_cd|wc
before: 96
after: 78
while:
pmap -px PID|grep 'rw.--'|grep -v anon|awk '{ sum+=$4 } END { print sum }'
for a --with-distro=CPLinux-LOKit build and spawned kit calc process from
2352 to 1860 pages
Change-Id: Ic0ea3e7934ac469f7c6225c252506adb5b62a4c2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/187742
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Some slots make sense in read-only files, when the application runs in
normal mode; but they make no sense in Viewer app mode. So this new flag
is orthogonal to the existing ReadOnlyDoc flag.
When it is FALSE, the respective command should not be active in the
viewer mode. The default is TRUE.
Change-Id: I5b5c75487fdf5a647aeab80129b6e84b42c00745
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177965
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Jenkins
because it takes a surprising amount of time to initialise it
at runtime during startup
(*) have to convert the std::function in SfxType to a
function pointer, because the std::function constructor
is not constinit compatible.
(*) the SfxType0..SfxTypeN types need some reinterpret_cast
to work around the lack of zero-sized trailing arrays in c++
(*) Sadly MSVC does not support taking the address of symbols
in constinit structures, so we cannot make the SfxSlot
array constinit.
Change-Id: I300ee770cc115d30bc25c819f2ad34b29633876c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166963
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This reverts commit 87d3f768f3.
The unit test at
starmath/CppunitTest_starmath_qa_cppunit.mk
is doing
$(eval $(call gb_CppunitTest_use_library_objects,starmath_qa_cppunit,\
sm \
))
which it is using to access to all the internal functions of starmath.
Unfortunately that linking trick is just not compatible with the mergelib linking.
Change-Id: Ie3c81a0eeea5bed192de18981463497f251531a6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164730
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Which means
(1) We need to extend the weak linkage magic for the sfx2 SFX_TYPEMAP
stuff. Just make it unconditional, since it makes no difference for the
individual items.
(2) The initialisation of global const Sequence data in starmath stops
working, because it runs too early. Use function-local static to
initialise it on-demand
Change-Id: Idc397515cd1d9621a06d237606c19acee600081a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164532
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
and :
cid#1545802 Using invalid iterator
cid#1545745 Using invalid iterator
cid#1545717 Using invalid iterator
cid#1545675 Using invalid iterator
cid#1545668 Using invalid iterator
cid#1545639 Using invalid iterator
cid#1545634 Using invalid iterator
cid#1545629 Using invalid iterator
cid#1545620 Using invalid iterator
cid#1545608 Using invalid iterator
cid#1545607 Using invalid iterator
cid#1545601 Using invalid iterator
Change-Id: I403842175f64a570d7e52fba7c3e03bf21b7d05b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160320
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
In slot.cxx, GetAttrCount() return a size_t type and same type can
be assigned directly to nSCount. In hash.hxx, sal_uLong was declared
in SvStringHashEntry, the only default parameter it the class takes
is aName (type OString) while nValue was directly initialized as 0
in the constructor. The interface to change nValue is through a method
setValue of same type.Also In idl/inc/hash.hxx SetValue() and GetValue functionsb are used in idl/source/prj/database.cxx with sal_uInt32 parameter and return type and thus, sal_uInt32 is suitable here.The instances of sal_uLong in source/objects/object.cxx are replaced with sal_uInt32. In object.cxx an iterator was declared using std::find
to find nId in rSuperList (originally declared as std::vector<sal_uLong>),
therefore if nId is sal_uInt32, the parent vector, rSuperList
should be sal_uInt32. This change is now applicable to the void method
InsertSlot's parameter rSuperList in object.hxx and also variables n,
nId, iter, rSuperList in InsertSlot definition block in the file
object.cxx. Variable aSuperList in obect.cxx is also changed to
sal_uInt32 because its an argument for rSuperList parameter.
nC1 and nC2 in idl/source/prj/svidl.cxx are chnaged from sal_uLong to size_t as this is suitable here.
Change-Id: Ie075875229a676ea32dbf9e3049881a479773703
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147220
Reviewed-by: Hossein <hossein@libreoffice.org>
Tested-by: Hossein <hossein@libreoffice.org>
We got a report on IRC of builds failing with
> svidl: /home/dolezvo1/Downloads/libreoffice/sal/rtl/ustring.cxx:278: void rtl_uString_newFromAscii(rtl_uString**, const char*): Assertion `static_cast<unsigned char>(*pCharStr) < 0x80' failed.
when the "l" in "Downloads" was some non-ASCII character (whose exact identity
was apparently obscured by the used pastebin service, though).
Change-Id: Ib460793b0f8aa5e8f8822fa224d67e5a622a234d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146664
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
The callgrind / mergelibs build fails with:
/svx/source/form/typemap.o: in function `aSvxColorItem_Impl´: \
multiple definition of `aSfxInt16Item_Impl´; \
/sfx2/source/appl/appbas.o: first defined here
Regression from commit 60d7796624
("sd theme: allow setting color effects in the sidebar").
Change-Id: Ibe382e2e12d3359caa3e853e264de0ede6a5e601
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127429
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
[CXX] sax/source/expatwrap/sax_expat.cxx
/home/pi/lo/libreoffice/idl/source/prj/database.cxx:437:23: error:
format specifies type 'unsigned long' but the argument has type
'sal_uInt64' (aka 'unsigned long long') [-Werror,-Wformat]
"error", nRow, nColumn );
^~~~
/home/pi/lo/libreoffice/idl/source/prj/database.cxx:437:29: error:
format specifies type 'unsigned long' but the argument has type
'sal_uInt64' (aka 'unsigned long long') [-Werror,-Wformat]
"error", nRow, nColumn );
^~~~~~~
2 errors generated.
Following https://cgit.freedesktop.org/libreoffice/core/commit/?id=5419b894a2e791de24d10f0c4433a807e175e7a0
author siddheshpatil777 <[hidden email]> 2021-01-06
14:14:33 +0400
committer Michael Stahl <[hidden email]> 2021-01-21
16:36:00 +0100
commit 5419b894a2 (patch)
tree 72cdf2b964
parent 21138573fc (diff)
tdf#114441: Convert use of sal_uLong to better integer types
Change-Id: I0d961e8b1e0a6a9709fabb50b5e209c7ac5e7250
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110844
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Julien Nabet <serval2412@yahoo.fr>
...for LIBO_INTERNAL_ONLY. These had been missed by
1b43cceaea "Make many OUString functions take
std::u16string_view parameters" because they did not match the multi-overload
pattern that was addressed there, but they nevertheless benefit from being
changed just as well (witness e.g. the various resulting changes from copy() to
subView()).
This showed a conversion from OStringChar to std::string_view to be missing
(while the corresponding conversion form OUStringChar to std::u16string_view was
already present).
The improvement to loplugin:stringadd became necessary to fix
> [CPT] compilerplugins/clang/test/stringadd.cxx
> error: 'error' diagnostics expected but not seen:
> File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 43 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:42): simplify by merging with the preceding assignment [loplugin:stringadd]
> File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 61 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:60): simplify by merging with the preceding assignment [loplugin:stringadd]
> 2 errors generated.
Change-Id: Ie40de0616a66e60e289c1af0ca60aed6f9ecc279
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107602
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
...in preparation of potential future changes from using OString to using
std::string_view, where OString has an undocumented feature of allowing
construction from a null pointer.
This is mostly the result of a manual audit of potentially problematic getenv
calls across the code base. But there can be other problematic places too, like
the xmlGetProp call in tools/source/xml/XmlWalker.cxx. To identify those,
rtl_{string,uString}_newFromStr aborts now in non-production debug builds when a
null pointer is passed(and all places that hit with a full `make check
screenshot` have been addressed here). Once we are confident that all
problematic places have been identified, we should drop support for the
undocumented feature (see the TODO in sal/rtl/strtmpl.cxx).
Change-Id: I595cc6d4f1cda74add2a3db171323f817d362b08
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107430
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>