office-gobmx/onlineupdate
Stephan Bergmann b1141fa610 Cut down on -pthread/-lpthread proliferation
Building against libstdc++ effectively always requires -pthread anyway (as
various standard C++ headers require it, see the comment added to
solenv/gbuild/platform/unxgcc.mk), so many explicit uses of -pthread/-lpthread
can be removed.

Doing a (partial) test build on Linux with Clang -stdlib=libc++ suggests that
libc++ indeed doesn't need -pthread as libstdc++ does.

The remaining uses of -pthread/-lpthread are mostly in configure.ac for the
various BSDs (which somebody else might want to clean up now), and related to
external projects.  I tried to be careful to remove -pthread/-lpthread from
makefiles only when C++ object files are involved (so -pthread will now be
included on the link command line by default).

Change-Id: I936e082839cb9a434bd273ce5a1f187a4245dfa1
Reviewed-on: https://gerrit.libreoffice.org/71291
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2019-04-25 21:27:43 +02:00
..
inc
qa
source work around Werror=format-truncation in onlineupdate for now 2019-02-15 18:19:53 +01:00
workben
astyle.options
CustomTarget_generated.mk
Executable_mar.mk Drop UNICODE/_UNICODE defines 2019-04-04 13:57:59 +02:00
Executable_mbsdiff.mk Drop UNICODE/_UNICODE defines 2019-04-04 13:57:59 +02:00
Executable_test_updater_dialog.mk Cut down on -pthread/-lpthread proliferation 2019-04-25 21:27:43 +02:00
Executable_update_service.mk Drop UNICODE/_UNICODE defines 2019-04-04 13:57:59 +02:00
Executable_updater.mk Cut down on -pthread/-lpthread proliferation 2019-04-25 21:27:43 +02:00
Makefile
Module_onlineupdate.mk
README
StaticLibrary_libmar.mk Drop UNICODE/_UNICODE defines 2019-04-04 13:57:59 +02:00
StaticLibrary_libmarverify.mk Drop UNICODE/_UNICODE defines 2019-04-04 13:57:59 +02:00
StaticLibrary_updatehelper.mk Drop UNICODE/_UNICODE defines 2019-04-04 13:57:59 +02:00
WinResTarget_updater.mk

Online update implementation based on Mozilla's MAR format + update mechanism

Parts of this code are copied from the mozilla repository, and adapted to
LibreOffice needs:

firefox/modules/libmar -> onlineupdate/source/libmar
firefox/toolkit/mozapps/update -> onlineupdate/source/update

The source/service directory contains the code for the silent windows updater that avoids the repeated administrator check for an update.

== NOTE ==
The updater executable should not depend on any other dynamic library in the LibreOffice installation as we would need to copy that one also to a temporary directory during update. We can't update any library or executable that is currently in use. For the updater executable we solve this problem by copying the updater before using it to a temporary directory.

On Windows we use the system to provide us with a crypto library whereas on Linux we use NSS.

== Update procedure ==

The updater executable is run two times. In a first run, the current installation is copied to a "update" directory and the update is applied in this "update" directory. During the next run, a replacement request is executed. The replacement request removes the old installation directory and replaces it with the content of the "update" directory.

=== User profile in the installation directory ===

The archive based installations have the user profile by default inside of the installation directory. During the update process this causes some problems that need special handling in the updater.

* The "update" directory is inside of the user profile resulting in recursive copying.
* During the replacement request the updater log is in the user profile, which changes location from the actual location to a backup location.