From d99fc6f2ad8b9078e9adc56796728d7e38b3ca80 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 13 Jan 2016 15:46:11 +0100 Subject: fix the MSVC 2013 --enable-lto build ... by sacrificing the appropriate number of chickens to the template dllexport gods. Change-Id: I27fb6a1f0a8a32c9bdc67574b3a2f3ec9f27b00f Reviewed-on: https://gerrit.libreoffice.org/21442 Tested-by: Jenkins Reviewed-by: Michael Stahl --- framework/inc/xml/acceleratorconfigurationreader.hxx | 2 ++ framework/inc/xml/imagesdocumenthandler.hxx | 1 + include/comphelper/containermultiplexer.hxx | 4 +++- include/comphelper/enumhelper.hxx | 6 +++++- include/oox/core/filterdetect.hxx | 3 ++- 5 files changed, 13 insertions(+), 3 deletions(-) diff --git a/framework/inc/xml/acceleratorconfigurationreader.hxx b/framework/inc/xml/acceleratorconfigurationreader.hxx index 206784213263..6dc343d3662b 100644 --- a/framework/inc/xml/acceleratorconfigurationreader.hxx +++ b/framework/inc/xml/acceleratorconfigurationreader.hxx @@ -20,6 +20,8 @@ #ifndef INCLUDED_FRAMEWORK_INC_XML_ACCELERATORCONFIGURATIONREADER_HXX #define INCLUDED_FRAMEWORK_INC_XML_ACCELERATORCONFIGURATIONREADER_HXX +#include // HACK: needed for MSVC 2013 ENABLE_LTO build: WeakImplHelper + #include #include #include diff --git a/framework/inc/xml/imagesdocumenthandler.hxx b/framework/inc/xml/imagesdocumenthandler.hxx index 6802369abb50..552e21159bc8 100644 --- a/framework/inc/xml/imagesdocumenthandler.hxx +++ b/framework/inc/xml/imagesdocumenthandler.hxx @@ -24,6 +24,7 @@ #include +#include // HACK: needed for MSVC 2013 ENABLE_LTO build: WeakImplHelper #include #include #include diff --git a/include/comphelper/containermultiplexer.hxx b/include/comphelper/containermultiplexer.hxx index f66024882e68..c3e77c62093b 100644 --- a/include/comphelper/containermultiplexer.hxx +++ b/include/comphelper/containermultiplexer.hxx @@ -69,9 +69,11 @@ namespace comphelper //= OContainerListenerAdapter + class SAL_DLLPUBLIC_TEMPLATE OContainerListenerAdapter_BASE + : public cppu::WeakImplHelper {}; class COMPHELPER_DLLPUBLIC OContainerListenerAdapter - :public cppu::WeakImplHelper< css::container::XContainerListener > + : public OContainerListenerAdapter_BASE { friend class OContainerListener; diff --git a/include/comphelper/enumhelper.hxx b/include/comphelper/enumhelper.hxx index 07edda974e1d..e6d115eac9a5 100644 --- a/include/comphelper/enumhelper.hxx +++ b/include/comphelper/enumhelper.hxx @@ -93,12 +93,16 @@ private: COMPHELPER_DLLPRIVATE void impl_stopDisposeListening(); }; +// this is the way that works for ENABLE_LTO with MSVC 2013 +class SAL_DLLPUBLIC_TEMPLATE OAnyEnumeration_BASE + : public ::cppu::WeakImplHelper {}; + /** provides an com.sun.star.container::XEnumeration for an outside set vector of Any's. */ class COMPHELPER_DLLPUBLIC OAnyEnumeration : private OEnumerationLock - , public ::cppu::WeakImplHelper< css::container::XEnumeration > + , public OAnyEnumeration_BASE { sal_Int32 m_nPos; css::uno::Sequence< css::uno::Any > m_lItems; diff --git a/include/oox/core/filterdetect.hxx b/include/oox/core/filterdetect.hxx index 679a4eb73869..9ecd9fea1679 100644 --- a/include/oox/core/filterdetect.hxx +++ b/include/oox/core/filterdetect.hxx @@ -83,8 +83,9 @@ private: }; +class SAL_DLLPUBLIC_TEMPLATE FilterDetect_BASE : public ::cppu::WeakImplHelper {}; -class OOX_DLLPUBLIC FilterDetect : public ::cppu::WeakImplHelper< css::document::XExtendedFilterDetection, css::lang::XServiceInfo > +class OOX_DLLPUBLIC FilterDetect : public FilterDetect_BASE { public: explicit FilterDetect( const css::uno::Reference< css::uno::XComponentContext >& rxContext ) -- cgit