From 25d114eec4d451acdda1ddff4c8ed9d47ba6275f Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Tue, 20 Mar 2012 23:18:55 +0200 Subject: Initial experiments with static linking of (some) components / services Start with the first service needed when running sc's filters_test: the UniversalContentBroker. It might not be typical as ucb uses the deprecated XSingleServiceFactory. This commit is not at all a complete solution, far from it, just an initial hack. Naturally once I come up with some generic enough way to do the static linking the necessary macros etc will be added to some general header. The macro XSERVICEINFO_IMPL_1 (local to ucbhelper and ucb) is amended so that it in the disable-dynamic-linking case also emits a function whose assembler name equal contains the service name. This function returns the XSingleServiceFactory for the service. Where the service is instantiated we link directly to that function. But probably this will be reworked a couple of times... Maybe it would be better to simply have the service name specific entry point be a pointer to the component's component_getFactory() function? Those all have the same prototype. --- ucb/source/ucp/webdav/webdavprovider.cxx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'ucb/source/ucp/webdav/webdavprovider.cxx') diff --git a/ucb/source/ucp/webdav/webdavprovider.cxx b/ucb/source/ucp/webdav/webdavprovider.cxx index ba24d632c276..8dbca76ebb87 100644 --- a/ucb/source/ucp/webdav/webdavprovider.cxx +++ b/ucb/source/ucp/webdav/webdavprovider.cxx @@ -93,10 +93,8 @@ XTYPEPROVIDER_IMPL_3( ContentProvider, //========================================================================= XSERVICEINFO_IMPL_1( ContentProvider, - rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( - "com.sun.star.comp.WebDAVContentProvider" )), - rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( - WEBDAV_CONTENT_PROVIDER_SERVICE_NAME )) ); + "com.sun.star.comp.WebDAVContentProvider", + WEBDAV_CONTENT_PROVIDER_SERVICE_NAME ); //========================================================================= // -- cgit