diff options
Diffstat (limited to 'desktop')
-rw-r--r-- | desktop/Library_libreoffice.mk | 1 | ||||
-rw-r--r-- | desktop/Module_desktop.mk | 7 | ||||
-rw-r--r-- | desktop/source/lib/init.cxx | 29 |
3 files changed, 29 insertions, 8 deletions
diff --git a/desktop/Library_libreoffice.mk b/desktop/Library_libreoffice.mk index 96b18a1bee7e..dbe3e81313a4 100644 --- a/desktop/Library_libreoffice.mk +++ b/desktop/Library_libreoffice.mk @@ -17,6 +17,7 @@ $(eval $(call gb_Library_set_include,libreoffice,\ $(eval $(call gb_Library_add_libs,libreoffice,\ $(if $(filter $(OS),LINUX), \ -ldl \ + -lpthread \ ) \ )) diff --git a/desktop/Module_desktop.mk b/desktop/Module_desktop.mk index d97bff3f1b1c..a05cceba6c76 100644 --- a/desktop/Module_desktop.mk +++ b/desktop/Module_desktop.mk @@ -33,7 +33,6 @@ $(eval $(call gb_Module_add_targets,desktop,\ AllLangResTarget_dkt \ Library_deployment \ Library_deploymentmisc \ - Library_libreoffice \ Library_offacc \ Library_sofficeapp \ Library_spl \ @@ -43,6 +42,12 @@ $(eval $(call gb_Module_add_targets,desktop,\ Zip_brand_dev \ )) +ifeq ($(OS),LINUX) +$(eval $(call gb_Module_add_targets,desktop,\ + Library_libreoffice \ +)) +endif + ifneq (,$(filter DESKTOP,$(BUILD_TYPE))) $(eval $(call gb_Module_add_targets,desktop,\ Executable_unopkg.bin \ diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx index de5788dd0420..06f5eac909d0 100644 --- a/desktop/source/lib/init.cxx +++ b/desktop/source/lib/init.cxx @@ -87,8 +87,20 @@ aBasicErrorFunc( const OUString &rErr, const OUString &rAction ) } static void -initialize_uno( const rtl::OUString &aUserProfileURL ) +initialize_uno( const rtl::OUString &aAppURL ) { + rtl::Bootstrap::setIniFilename( aAppURL + "/fundamentalrc" ); + + OUString aValue; + rtl::Bootstrap::set( "CONFIGURATION_LAYERS", + "xcsxcu:${BRAND_BASE_DIR}/share/registry " + "res:${BRAND_BASE_DIR}/share/registry " +// "bundledext:${${BRAND_BASE_DIR}/program/unorc:BUNDLED_EXTENSIONS_USER}/registry/com.sun.star.comp.deployment.configuration.PackageRegistryBackend/configmgr.ini " ); +// "sharedext:${${BRAND_BASE_DIR}/program/unorc:SHARED_EXTENSIONS_USER}/registry/com.sun.star.comp.deployment.configuration.PackageRegistryBackend/configmgr.ini " +// "userext:${${BRAND_BASE_DIR}/program/unorc:UNO_USER_PACKAGES_CACHE}/registry/com.sun.star.comp.deployment.configuration.PackageRegistryBackend/configmgr.ini " +// "user:${$BRAND_BASE_DIR/program/bootstraprc:UserInstallation}/user/registrymodifications.xcu" + ); + xContext = cppu::defaultBootstrap_InitialComponentContext(); fprintf( stderr, "Uno initialized %d\n", xContext.is() ); xFactory = xContext->getServiceManager(); @@ -96,8 +108,9 @@ initialize_uno( const rtl::OUString &aUserProfileURL ) comphelper::setProcessServiceFactory(xSFactory); // set UserInstallation to user profile dir in test/user-template - rtl::Bootstrap aDefaultVars; - aDefaultVars.set(rtl::OUString("UserInstallation"), aUserProfileURL ); +// rtl::Bootstrap aDefaultVars; +// aDefaultVars.set(rtl::OUString("UserInstallation"), aAppURL + "../registry" ); + // configmgr setup ? } bool @@ -117,15 +130,17 @@ LibLibreOffice_Impl::initialize( const char *app_path ) return false; try { - initialize_uno( aAppURL + "../registry" ); + initialize_uno( aAppURL ); force_c_locale(); + + // Force headless + rtl::Bootstrap::set( "SAL_USE_VCLPLUGIN", "svp" ); InitVCL(); - if (Application::IsHeadlessModeRequested()) - Application::EnableHeadlessMode(true); + Application::EnableHeadlessMode(true); ErrorHandler::RegisterDisplay( aBasicErrorFunc ); - fprintf (stderr, "do nothing yet"); + fprintf( stderr, "initialized\n" ); bInitialized = true; } catch (css::uno::Exception & e) { fprintf( stderr, "bootstrapping exception '%s'\n", |