Commit Graph

358 Commits (master)

Author SHA1 Message Date
Ashod Nakashian 5c9988f2e3 wsd: faster jail setup via bind-mount
loolmount now works and supports mounting and
unmounting, plus numerous improvements,
refactoring, logging, etc..  When enabled,
binding improves the jail setup time by anywhere
from 2x to orders of magnitude (in docker, f.e.).

A new config entry mount_jail_tree controls
whether mounting is used or the old method of
linking/copying of jail contents. It is set to
true by default and falls back to linking/copying.
A test mount is done when the setting is enabled,
and if mounting fails, it's disabled to avoid noise.

Temporarily disabled for unit-tests until we can
cleanup lingering mounts after Jenkins aborts our
build job. In a future patch we will have mount/jail
cleanup as part of make.

The network/system files in /etc that need frequent
refreshing are now updated in systemplate to make
their most recent version available in the jails.
These files can change during the course of loolwsd
lifetime, and are unlikely to be updated in
systemplate after installation at all. We link to
them in the systemplate/etc directory, and if that
fails, we copy them before forking each kit
instance to have the latest.

This reworks the approach used to bind-mount the
jails and the templates such that the total is
now down to only three mounts: systemplate, lo, tmp.

As now systemplate and lotemplate are shared, they
must be mounted as readonly, this means that user/
must now be moved into tmp/user/ which is writable.

The mount-points must be recursive, because we mount
lo/ within the mount-point of systemplate (which is
the root of the jail). But because we (re)bind
recursively, and because both systemplate and
lotemplate are mounted for each jails, we need to
make them unbindable, so they wouldn't multiply the
mount-points for each jails (an explosive growth!)
Contrarywise, we don't want the mount-points to
be shared, because we don't expect to add/remove
mounts after a jail is created.

The random temp directory is now created and set
correctly, plus many logging and other improvements.

Change-Id: Iae3fda5e876cf47d2cae6669a87b5b826a8748df
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92829
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2020-07-01 05:42:43 +02:00
Szymon Kłos 3141bf7775 notebookbar: Introduce switch in loolwsd.xml
Change-Id: I94546a899fde1cecc2c35dc527e41e8a36061750
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/93050
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
2020-06-30 08:16:25 +02:00
Jan Holesovsky 661bb47d07 android: Add x86-64 build too.
This will make it possible to create AAB's that contain 3 ABIs:
armeabi-v7a, arm64-v8a and x86_64.

If you want to build for just one ABI, use --with-android-abi=... where
the value is one of those three above.

Change-Id: I553b8ca941db67eddc1d712a96b818f9cfedd0fa
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/97227
Tested-by: Jan Holesovsky <kendy@collabora.com>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2020-06-29 14:24:36 +02:00
Henry Castro 2eec63af29 android: add "x86_64" ABI build variant
Change-Id: I19281af5432ae5a02f26f33464ced722759a4c67
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/95609
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-06-11 20:11:44 +02:00
Henry Castro 8e1cf47112 loleaflet: remove install node_module in configure phase
Fair enough, let's not get in conflict with IOS platform,
It is restored and get another solution

Change-Id: I1cde236595479bdf41e29d8a30bb9d71aa196e54
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/95036
Tested-by: Henry Castro <hcastro@collabora.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-05-28 14:30:22 +02:00
Tor Lillqvist 48a5397ff4 Run the 'npm install' at configure time only on Linux
I don't want to make it necessary to have npm on macOS (in the case of
building the iOS app, otherwise Online is Linux-only). I still want to
use the method where the JS bits are built on a Linux machine and
loleaflet/dist is copied over to the Mac where you build the iOS app.

Remove the apparently never seriously used instructions for the other
way from ios/README. If somebody actually *uses* that way for real,
for a longer time, then please reinstate them, and modify
configure.ac, etc.

Change-Id: I22a8ca4746907bb11aad11d7c995b0de2fdbc157
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/94815
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tor Lillqvist <tml@collabora.com>
2020-05-26 09:02:14 +02:00
Henry Castro 40dffc408c loleaflet: install node modules in configure phase
It is not necessary to clean these files since
they do not change frequently

Change-Id: I092013c02effffe6c45bccbf81369e583cffe806
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/93111
Tested-by: Jenkins
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-05-25 20:13:24 +02:00
Henry Castro 16028271bb cypress: fix running single unit test
When builddir != srcdir

Stills error:

"The support file is missing or invalid.

Your `supportFile` is set to `cypress_test/support/index.js`, but either
the file is missing or it's invalid. The `supportFile` must be a `.js`
or `.coffee` file or, if you're using a preprocessor plugin, it must be
supported by that plugin.

Correct your `cypress.json`, create the appropriate file, or set
`supportFile` to `false` if a support file is not necessary for your
project."

Change-Id: If1aeb55a3821735022dfa57af217130f18cd9dbf
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/94424
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-05-22 21:08:59 +02:00
Henry Castro e6f5917812 cypress: fix error running single unit test
builddir != srcdir

Change-Id: I2521c3e11f05f0c91bf0e8f5667a5466493acac0
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/94080
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-05-13 16:51:29 +02:00
Andras Timar 33000dfded typo fixes in comments and code
Change-Id: I6f31e050aab701e31064e1abc9429dce0a50c279
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92953
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-04-26 23:19:52 +02:00
Henry Castro a2410c599c android: convert remaining rules to gradle tasks
It will give an Independence (at least) to the
gradle build system to package the product

Change-Id: I127c2f921b506ec280a244d609707f3480e0f92e
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92719
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-04-23 09:09:11 +02:00
Henry Castro 53a27a1ec4 android: set specific DEST:SOURCE config files
The *.in files in android should be generated
explicitly in source dir. With this setting it is
enabled to configure builddir != srcdir

Change-Id: I529f8021d4407b2f87ae265b93fb3d764bb1a1bf
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92595
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-04-21 16:28:13 +02:00
Henry Castro 0e8942f88f android: configure build directory
Enable to change to build directory when
builddir != srcdir

Change-Id: I8e48897c44a5ea67da8ffebc3183d722a05e3a20
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92596
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-04-21 16:03:38 +02:00
Henry Castro bc4885b64a android: generate only the necessary config files
Avoid generates files that are not needed to develop android

Change-Id: Ica882e3faeaa800e03e8bf811c81c328a7dff6a3
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92138
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-04-20 23:58:50 +02:00
Muhammet Kara f507302993 Welcome: Add config for enabling the dismiss button
Change-Id: Ia2fbf066493d91a2b10866e66d11332b5cfc10fa
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92593
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2020-04-20 20:35:08 +02:00
Jan Holesovsky cf1cd4dd1d Welcome: Better default when the welcome.enabled is not present in config.
Change-Id: Ia528f1cdf16af9b9724c31f9b1df8b51efb664fb
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92341
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2020-04-16 12:43:37 +02:00
Jan Holesovsky 0ec796dbee Welcome: Add ./configure of the welcome message default.
Change-Id: I090c7d657d2b0a696117f64f25c11ffb249fb272
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92277
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2020-04-16 11:36:00 +02:00
Michael Meeks a7dc2d1467 kill IoUtil - obsolete & unused.
The switch away from LOOLWebSocket and the use of a websocket
for talking to forkit removes the need for the pipe code.

Change-Id: Ifb0c6c88681289e7a1709d9bc3281532935c7be4
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92033
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-04-10 16:38:25 +02:00
Michael Meeks 5710c86323 Poll - switch to ppoll for closer to microsecond accuracy.
Change-Id: Ib8a2bb6f60302df8631edadbbb8db626894c457c
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92000
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-04-10 10:06:23 +02:00
Michael Meeks fa14102b3b Restore Javascript protocol logging.
If you don't want protocol logging by default in debugging builds
then either poke loolwsd.xml:

<protocol type="bool" descr="Enable minimal client-site JS protocol logging from the start">false</protocol>

Or - configure with --disable-debug and --disable-debug-protocol.

Also remove redundant and unused co-ordinate parameters to the
message queue, and logging.

Change-Id: I489e32ef4758a6f0ef35c8d8d322a402a3e268e6
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91096
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-03-26 19:35:04 +01:00
Corentin Noël dbaf32c627 autotools: Add support for atomic helper library
On some platforms like Raspbian Buster, loolwsd need to be linked to the atomic helper library.

Change-Id: I0a8b921d85d499040b2e65d480116cbcb14b5089
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91102
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-03-26 15:32:30 +01:00
Tor Lillqvist 4dd95f833d Propagate core and online git hashes to the Settings for the iOS app
The git hashes now show up in the Settings app, without having to run
the Collabora Office app, open a document, and check the About dialog.

The core git hash is taken from the core build directory's
instdir/program/setuprc.

Also, drop the fairly pointless lone Finnish localisation of the
Settings strings.

Change-Id: I56631f8facde017ed99038209c55f516386eab99
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91073
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tor Lillqvist <tml@collabora.com>
2020-03-26 00:26:58 +01:00
mert 76f4c6de3b android: added a rating dialog
Change-Id: If1fed5bff1f7b607027d01a69d09de997fae8473
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90479
Tested-by: Jan Holesovsky <kendy@collabora.com>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2020-03-18 00:36:05 +01:00
Miklos Vajna 7193699742 libfuzzer: don't require a core.git installation set
The fuzzer focuses on catching protocol parsing problems, it's not an
end-to-end test.

Change-Id: I1edc308134f365749339790f242614332b54dce4
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89720
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-02-28 18:31:53 +01:00
Tor Lillqvist 3de577d2c2 Use the loolkitconfig-mobile.xcu on iOS, too
We can't rename a file in the Xcode project, so copy it to
ios/Mobile/loolkitconfig.xcu in the configure script, and use from
there.

Change-Id: I1e50235c06f528dd24d0d968aaccc994418b57d8
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89466
Tested-by: Tor Lillqvist <tml@collabora.com>
Reviewed-by: Tor Lillqvist <tml@collabora.com>
2020-02-25 21:40:03 +01:00
Miklos Vajna 57a35bb96c Add an initial libfuzzer based fuzzer
- target ClientSession::_handleInput(), since crashing there would bring
  down the whole loolwsd (not just a kit process), and it deals with
  input from untrusted users (browsers)

- add a --enable-fuzzers configure switch to build with
  -fsanitize=fuzzer (compared to normal sanitizers build, this is the only
  special flag needed)

- configuring other sanitizers is not done automatically, either use
  --with-sanitizer=... or the environment variables from LODE's sanitizer
  config

- run the actual fuzzer like this:

  ./clientsession_fuzzer -max_len=16384 fuzzer/data/

- note that at least openSUSE Leap 15.1 sadly ships with a clang with
  libfuzzer static libs removed from the package, so you need a
  self-built clang to run the fuzzer (either manual build or one from
  LODE)

- <https://chromium.googlesource.com/chromium/src/testing/libfuzzer/+/refs/heads/master/efficient_fuzzing.md#execution-speed>
  suggests that "You should aim for at least 1,000 exec/s from your fuzz
  target locally" (i.e. one run should not take more than 1 ms), so try
  this minimal approach first. The alternative would be to start from the
  existing loolwsd_fuzzer binary, then step by step cut it down to not
  fork(), not do any network traffic, etc -- till it's fast enough that
  the fuzzer can find interesting input

- the various configurations start to be really complex (the matrix is
  just very large), so try to use Util::isFuzzing() for fuzzer-specific
  changes (this is what core.git does as well), and only resort to ifdefs
  for the Util::isFuzzing() itself

Change-Id: I72dc1193b34c93eacb5d8e39cef42387d42bd72f
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89226
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2020-02-22 12:18:22 +01:00
Henry Castro 0c79556128 cypress: configure: fix symbolic links to files and folders
builddir != srcdir

Change-Id: I7baaba5f173d209cfb6cbbc5a61cf07a66a51eaf
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/88560
Tested-by: Henry Castro <hcastro@collabora.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-02-13 15:29:16 +01:00
Yunusemre Şentürk f54afcbebc Add chromium-browser to binary search pool
Change-Id: If82be88891f9d506c2791e993c580eaef459f937
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/88087
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2020-02-06 12:19:52 +01:00
Miklos Vajna 2afebbeb67 configure: make lack of Chrome an error in the enable-cypress case
Change-Id: I1e2d4c884fc58334b3fdd5d43b1821eceeb08987
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/87487
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-01-27 09:44:29 +01:00
Tamás Zolnai aaab96fd12 cypress: make chrome check depend on enable_cypress flag.
Change-Id: I0e61ef55be68991ae6d55247d93beb0cd6913084
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/87292
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-01-23 21:02:46 +01:00
Tamás Zolnai 0145c03ed6 cypress: Introduce an --enable-cypress config option.
Removing the cypress_test subdir from top level
folder made the packaging process to fail.
So better to use a flag to enable cypress tests.

Change-Id: Iead4b7cbbea5c6aaba18c0b85f23d67a4fbe920b
2020-01-23 14:55:43 +01:00
Tamás Zolnai dbb87bab34 cypress: Fix CHROME program detection.
For checking more binaries, we need AC_PATH_PROGS and
a blank separated list.

Change-Id: Ie1f5660b912970b70ba1aa51885989fbd0563914
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/87213
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-01-22 21:21:37 +01:00
Miklos Vajna ed586d9601 cypress: accept chromium next to chrome
Change-Id: Id2a577b1413227840e2af29abe4cc96e5a81dd82
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/87191
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Miklos Vajna <vmiklos@collabora.com>
2020-01-22 18:59:46 +01:00
Tamás Zolnai 524bbb3398 cypress: Initial integration of cypress test framework.
Change-Id: Ibf300b33d32ce3e7f1affbaf0a59364ddb618b56
2020-01-21 16:13:01 +01:00
Andras Timar 684aafd0e1 Revert "Bump package version to 4.2.0-3 and update deb/rpm package files"
This reverts commit b0b2e8f5e8.
2020-01-10 12:17:43 +01:00
Andras Timar b0b2e8f5e8 Bump package version to 4.2.0-3 and update deb/rpm package files
Change-Id: I935425f644f373acdd4bf8d073ec8be3f29313b8
2020-01-10 12:08:08 +01:00
Jan Holesovsky d556760c2f android: Implement (optional) support for both 32bit and 64bit build.
This adds possiblity to specify additional build trees for LibreOffice
and POCO that contain the 64bit version, like:

    --with-lo-builddir=/local/libreoffice/master-android-release:/local/libreoffice/master-android-release-64bit \
    --with-poco-includes=/opt/poco-android/include:/opt/poco-android-64bit/include \
    --with-poco-libs=/opt/poco-android/lib:/opt/poco-android-64bit/lib \

which triggers both 32bit and 64bit build.

It should be still possible to build just 32bit when used without the
semicolons - which is useful for the normal development.

Change-Id: I99145e57f0cc15f022c05d09f8c4ab275880d44b
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/84312
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-30 14:24:30 +01:00
Jan Holesovsky 1c8a31b33e android: Brand also the shell's About dialog.
Change-Id: I63b668ad92c688ec69818c058a787dbd94b5cc8b
Reviewed-on: https://gerrit.libreoffice.org/84630
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2019-12-06 15:46:04 +01:00
Jan Holesovsky 814a0c49ef android: Allow full version specification.
Change-Id: I2da4a7d1fc63cfd0df10a7e32f123af82e8be461
Reviewed-on: https://gerrit.libreoffice.org/84329
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-03 14:52:00 +01:00
Jan Holesovsky d87f06adef android: Add possibility to brand the launcher icon.
Change-Id: I6cd531aab698236287eb7c20146caa61e34e8450
Reviewed-on: https://gerrit.libreoffice.org/84328
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-12-03 14:34:47 +01:00
Andras Timar 8d5d9e427f APP_NAME tweaks
Change-Id: I16016cfc575620f98c0124fdb85e39cf56e0453a
2019-11-27 12:16:07 +01:00
Andras Timar c59bf4ed3a ENABLE_DEBUG default value should be false and not empty
When the default value was empty, @ENABLE_DEBUG@ in loolwsd.xml.in
was substituted to empty string, not to "false" as intended in release
builds. As a consequence, in new installations, the loading of the
loleaflet.html gave 400 Bad request error with a not very helpful
error message:
wsd-00922-00928 2019-11-24 16:05:55.384859 [ websrv_poll ] INF  #23 Exception while processing incoming request: [POST /loleaflet/08aa7d914/loleaflet.html?WOPISrc=http%3A%2F%2F172.22.64.173%2Findex.php%2Fapps%2F...]: Syntax error| wsd/LOOLWSD.cpp:2244euex4o&title=About.odt&lang=en&closebutton=1&revisionhistory=1 HTTP/1.1

Change-Id: Ia8bb18914bb49af057c4618f99124b0f22737f20
2019-11-24 17:36:24 +01:00
Tor Lillqvist bdc2777798 Require use of --with-vendor when configuring for the iOS app
You want something meaningful to show up in Help > About, not just
your account's login name.

Change-Id: I1f30516200552f2bbe70091efa3b7029954a681a
2019-11-21 11:30:18 +02:00
Jan Holesovsky 888a9e56ab android: Back to using POCO.
It turns out that the std::filesystem is still not part of the NDK:
https://github.com/android/ndk/issues/609

The NDK has the header - but not the c++fs library yet :-(

Change-Id: Ic7003f71cd4730b2f34138adea3b09fe92fdbb4a
Reviewed-on: https://gerrit.libreoffice.org/82336
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-11-09 00:33:25 +01:00
Jan Holesovsky 07d5f8cf2a killpoco: Remove POCO usage from FileUtil.cpp when C++17 is available.
This introduces basic C++17 support, because the functionality needed
here is easy to implement using std::filesystem.

Adds also the necessary checks to ./configure.  The code still uses POCO
when C++17 is not available in the compiler.

Change-Id: I03353834d10201bf0a13ea72715560b9b9b16265
Reviewed-on: https://gerrit.libreoffice.org/82294
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-11-08 13:56:09 +01:00
Jan Holesovsky 13df611403 android: Allow specifying the versionCode from ./configure.
Change-Id: If3f618bd836d236e76bd4698321ec7314ebac1a4
Reviewed-on: https://gerrit.libreoffice.org/82177
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-11-07 09:39:48 +01:00
Tor Lillqvist 2c8350b8a1 Don't require the Python modules unless on Linux
When building the iOS app my way, I do the J bits on a Linux box and
not on the Mac, thus I don't need any Python stuff on the Mac.

Change-Id: Ib8092870598fb3a8f304aefa8fab21fe7e3acc73
Reviewed-on: https://gerrit.libreoffice.org/82018
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
2019-11-04 15:25:38 +01:00
Andras Timar 5a0e357f78 add -lssl and -lcrypto to LIBS, if SSL is enabled
Without this the linking with static poco libs failed on Ubuntu
16.04 and 18.04. Interestingly on other distros, including Debian
8, 9, 10, and CentOS 7, 8, and openSUSE, this patch was not necessary.

Change-Id: I96c90ab5e960e8843db9b835f6e1a0417c7b48f8
Reviewed-on: https://gerrit.libreoffice.org/81836
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2019-10-31 14:28:19 +01:00
Andras Timar 5e4c9db5de fix configure check 'If we need to link with -lpcre'
The test program did not compile because of
error: unused parameter 'argc' [-Werror=unused-parameter]
As result, we always linked with -lpcre.

Change-Id: I7557025cc56fb72fc2a9f8de6142de93cfed2335
2019-10-30 13:51:48 +01:00
Yunusemre Şentürk 3c4f900b45 change linking order of poco libs in order to make static linking possible
Change-Id: I8de3f454f9174d78777303779acdb6c9c1ba2c7c
2019-10-30 10:03:49 +01:00
Michael Weghorn f75366bc94 configure.ac: Add check for python3 libs
They are needed since commit
c1e04e4069
("scripts/unocommands.py: Switch to python3"),
so add a corresponding check to configure.ac.

Change-Id: If0f1d2b474c3edb3fc63dc54292acd54f096b822
Reviewed-on: https://gerrit.libreoffice.org/81473
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Michael Weghorn <m.weghorn@posteo.de>
2019-10-25 09:51:43 +02:00
Tor Lillqvist 9c2fd9ded9 The --with-lo-path is not necessary when building for iOS or Android
Change-Id: Ib245058f1a3e985547e9a44dd4c8ebc613875cb6
Reviewed-on: https://gerrit.libreoffice.org/80444
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
2019-10-08 16:40:33 +02:00
Andras Timar db176ee45b Remove lo_template_path option
It was not very useful to let this setting configurable by the user.
On the other hand, old path in config file caused issues after
upgrade. It is better to decide the location of LOKit core
during compilation. From now on the --with-lo-path configure
option is compulsory.

Change-Id: Icdcbc21bde5dad329fdb6e30ed17efde6b0e73de
Reviewed-on: https://gerrit.libreoffice.org/79943
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2019-10-08 09:36:44 +02:00
Tor Lillqvist 163f6f5f5e It's ios/Mobile/Branding that we want
Change-Id: I059189b7268b41515d12ef245b52f6eb6117f9b4
(cherry picked from commit 5cd866441d)
Reviewed-on: https://gerrit.libreoffice.org/79385
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
2019-09-23 10:44:44 +02:00
Ashod Nakashian 90188d07c1 configure: support sanitizers
It is now possible to run ./configure --with-sanitizer=address
(or any least of valid sanitizers) to build with sanitizers.

When --with-sanitizer is specified, we build with -O1 and
don't omit frame-pointer. We also enable RTTI (which should
be enabled anyway, but just in case).

UBSan (undefined) sanitizer can cause 'typeinfo' errors.
Fixing the source is best, but as a workaround, disabling
vptr sanitizer works. Just pass -fno-sanitize=vptr to CFLAGS
and CXXFLAGS.

Change-Id: I4031aa872b1b1ef779703135394f3733952e5cd1
Reviewed-on: https://gerrit.libreoffice.org/79329
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-09-22 20:26:25 +02:00
Ashod Nakashian 226c2fe71c wsd: unify anonymization flags under one
This simplifies the anonymization configuration
as virtually always they are all either enabled
together, or not at all.

Change-Id: I6fe60f5287fc5d71cd7a6ac3268eac67e5e6e9fb
Reviewed-on: https://gerrit.libreoffice.org/70033
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Reviewed-on: https://gerrit.libreoffice.org/71090
2019-08-17 03:42:19 +02:00
Jan Holesovsky 2b13c69d75 android: Split the actual editing Activity into an own library.
This way, it is more naturally visible what is the actuall app (with the
initial recent documents / file picker) and the editing part.

Change-Id: Ia764f2900939e980f703e3da9f9abd6c0aee7cbb
2019-07-12 11:52:56 +02:00
Samuel Mehrbrodt 16fcd37201 configure: Add support for custom icons
Change-Id: I573b4d7e745cdea6fdbecd2c3790078d1980bdf9
Reviewed-on: https://gerrit.libreoffice.org/74491
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-06-28 12:32:43 +02:00
Jan Holesovsky f77c8cd967 android: make clean should clean the assets too.
Change-Id: I1cb2ddb1a7ed71234a5ffc9bdf3631d701df6e5c
2019-06-20 14:14:00 +02:00
Jan Holesovsky f485b2ea97 android/ios: Turn the --with-iosapp-branding into --with-app-branding.
This is needed for the Android app too, so generalize the switch.

Kill copying of the example documents into the APK when at that...

Change-Id: I5b575ade3e40cc0becd5c739077acff5299d3312
2019-06-20 14:13:09 +02:00
Jan Holesovsky 61f6189a99 android: Allow providing the package name via --with-android-package-name.
And when at that, tweak some settings for the release configuration.

Change-Id: Ib8dab481fb7734637076603347f8fde453455fda
2019-06-20 14:12:55 +02:00
Tor Lillqvist 199c6e2918 Revert "Get rid of use of GNU libtool" and its follow-up
The change causes problems for people on various sad distros. Oh well,
whatever.

This reverts commit bd00d9fd05.
This reverts commit 054a9cdb04.

Change-Id: Ie439e4c655d02b6f34bdd1a9c1c5b6db6048b653
2019-05-27 10:25:51 +03:00
Tor Lillqvist bd00d9fd05 Get rid of use of GNU libtool
It is is complicated enough to build the iOS app. Requiring GNU
libtool brings with it the risk of polluting the command environment
as there already is a completely different command in macOS with the
same name, /usr/bin/libtool. And as GNU libtool was used only to build
the unit tests for the "normal" server-based Online that are built and
run only on Linux anyway, we don't really need any of the
"portability" that GNU libtool brings.

Without GNU libtool, we compile all the $(wsd_sources) (see
test/Makefile.am) that the unit-* tests use into a single object file,
WsdSources.o. (Because they need to be compiled as PIC we can't use
the already compiled object files for the Online server programs.)
This required some additional minor changes to a few source files.

Change-Id: I20a2c523170376fa4c1a0d9d8d6b693a9779376f
Reviewed-on: https://gerrit.libreoffice.org/72840
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
2019-05-24 09:50:16 +02:00
Samuel Mehrbrodt cbbe43fcff Revert "Change package name to "libreoffice-online" instead of "loolwsd""
As discussed on IRC: This leads to incompatible changes (config directory changed) and instead we will use loolwsd on master branch too from now on.

This reverts commit 1dbbc5acc7.

Change-Id: Ifa38144f830578c12cda7454354b60d09426e704
Reviewed-on: https://gerrit.libreoffice.org/72734
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-22 12:07:07 +02:00
Samuel Mehrbrodt 1dbbc5acc7 Change package name to "libreoffice-online" instead of "loolwsd"
The name on master is "loolwsd" while the official relase branches
(libreoffice-6-2 e.g.) have "libreoffice-online".

This leads to various issues, e.g. some scripts expect the config files
to be in /etc/loolwsd while changing the name also changes that folder name
to /etc/libreoffice-online.
So at least docker builds from the release branches don't work.

The package name should be consistent, either we use "libreoffice-online"
on master also, or we change the release branches to also use "loolwsd".

My preference is to have "libreoffice-online" as the name. "loolwsd" is an
internal term and hard to associate with LibreOffice online for "outsiders".

Change-Id: I1b1efda2fa6083f1a0d211fd73f1fa062f3286cc
Reviewed-on: https://gerrit.libreoffice.org/72590
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2019-05-21 17:29:15 +02:00
Tor Lillqvist 60581962af Add branding to the iOS app
A configure argument, --with-iosapp-branding, should point to a
directory containing a branding.css file and possibly other files that
branding.css references, to be bundled and used by the iOS app. The
directory structure ends upp in the app bundle as Branding. The
generated loleaflet.html for the iOS app references
Branding/branding.css unconditionally.
2019-04-22 17:23:20 +03:00
Jan Holesovsky 2c174e3c30 android: Introduce --with-vendor and --with-info-url.
For the Android's 'shell' About dialog box; includes also some fixes to
that dialog.

Change-Id: I0c9f660da981b653608bf11e1eaccb283feb513f
2019-04-16 12:59:43 +02:00
Jan Holesovsky ea659b3d99 Use the app name more generally, not only on iOS.
Preparation for using it on Android too.

Change-Id: Iee7778b2625a02a98daff5df87c39f4ab1d18144
Reviewed-on: https://gerrit.libreoffice.org/70651
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
2019-04-12 13:44:40 +02:00
Samuel Mehrbrodt f46d5e9845 NPM: require at least v5.0.0
This is necessary after 338563ab45

Change-Id: I026dba613349931a95fd71b126e72605d1546140
Reviewed-on: https://gerrit.libreoffice.org/70054
Reviewed-by: Alexandru Vlăduţu <alexandru.vladutu@1and1.ro>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-04-01 13:37:35 +02:00
Henry Castro da2bdd62da configure: update links for directory "archived-packages"
Change-Id: Iea7d5f867b5a7a2f987b0513d33ffb675729de97
2019-03-30 16:35:40 -04:00
Jan Holesovsky 081da013b5 Revert "configure: add Boost.Locale library"
This reverts commit b1bec2f500.
2019-03-15 17:28:14 +01:00
Jan Holesovsky 95f4d70ea7 Revert "configure: check "msgfmt" installation"
This reverts commit a6b2708ef5.
2019-03-15 17:27:51 +01:00
Henry Castro a6b2708ef5 configure: check "msgfmt" installation
Change-Id: Ib6661e3e79e4ceba6379097875d5d1e7998838e6
2019-03-05 17:31:57 -04:00
Henry Castro b1bec2f500 configure: add Boost.Locale library
use --with-boost-libdir=LIB_DIR

Change-Id: I7c01fa33ce1dafcfc636ddcdeae46111b2ccab8e
2019-03-05 16:58:22 -04:00
Tor Lillqvist ce53efd880 Keep the iOS app bundle version in a file in the build folder, not in git
When you want to build a new version for distribution, bump the
build number in the BUNDLE-VERSION file.

Change-Id: I1e7e55528aef6d3526ce14d070ae96abc5931f38
2019-02-25 09:14:14 +02:00
Szymon Kłos 8a61a53027 Integrate browser-sync
Tool to automatically reload used .css and .js files.
To make it work symlinks are created instead of a copy
if browsersync is enabled.

1. install:
npm install -g browser-sync

2. use configure option: --enable-browsersync

3. remove loleaflet/dist directory

4. run server:
LOOL_SERVE_FROM_FS=1 make run -j10

5. run browsersync:
browser-sync start --config browsersync-config.js

or

make sync-writer

Change-Id: Iebee1cc0b9a03bc866954ff33e3cb8a10b48e0af
2019-02-21 09:23:47 +01:00
Tor Lillqvist 8f71365f0f Remove unnecessary leftovers after Michael's removal of the on-disk tile cache
Change-Id: I435679b48f90d2580bb9c5c86a26c9a1d43c5b59
Reviewed-on: https://gerrit.libreoffice.org/67885
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2019-02-15 21:36:16 +01:00
Jan Holesovsky 427c5ea219 android: Settings for the build.gradle.
Change-Id: I457a7fb8a80106c0474ee03229e712a557cf799b
2019-02-15 16:53:35 +01:00
Jan Holesovsky 7a0209c7aa android: Link against the debug POCO libraries if --enable-debug.
Change-Id: Ic7dc3076a12fe9a0faf4dec5c0f5b0b3a5a171c3
2019-02-13 17:28:01 +01:00
Jan Holesovsky e79f5f7ec6 android: Create the html, js and css and copy it to the right place.
Change-Id: I3efbba0ae369387796e2d08b3003e4f469610dda
2019-02-13 13:22:25 +01:00
Jan Holesovsky 6d8d40a267 android: Use configure for the rest of the hardcoded stuff in CMakeLists.txt.
Change-Id: I61ae98c87f439dffe6df4b9c61da7e7c5f968786
2019-02-13 12:09:36 +01:00
Jan Holesovsky 3af9580489 android: Generate the CMakeLists.txt from configure.
Change-Id: I9012e78adda55640c6fe74829fcb7f7a2fb25ce6
2019-02-13 11:32:49 +01:00
Jan Holesovsky f76b36193d android: #if(n)def MOBILEAPP -> #if (!)MOBILEAPP for better reliability.
Change-Id: I5f9c9420b6c83601db1c8fdba4ae5a10b17b2107
2019-02-12 12:20:11 +01:00
Jan Holesovsky d15fc93f31 android: Define MOBILEAPP via config.h. 2019-02-12 10:50:40 +01:00
Jan Holesovsky e780a02171 android: Make it to ./configure.
Make of course immediately fails.
2019-02-12 10:50:40 +01:00
Tor Lillqvist 0a5a711231 Create the ios/Mobile/Fonts directory even if we won't copy any fonts there
It is referenced unconditionally in the Xcode project file.

Change-Id: I1f6713b5327740f76e90ea88dfb19a4933d0bce3
2019-01-22 23:50:19 +02:00
Samuel Mehrbrodt 4691d2b18a Add some messages whether we are building with support key
Change-Id: If41767c549e9e46b7f0a6f23fa5d819a946f9bdb
2019-01-08 18:49:12 +01:00
Andras Timar 279301e51d New configure switch --enable-vereign to set the default document signing url
Change-Id: I65225fc5f94a8ad49b75d31ef3535e8479484e69
2018-12-11 12:55:16 +01:00
Tor Lillqvist 3c046b0548 Add --with-iosapp-fonts option to bundle some 3rd-party fonts in the app
Propagate the font files found in that folder to Info.plist and to the
app bundle.

Change-Id: I2c38b0d7d21dbdf3b7ffd3b4ae98e47b9ad74758
2018-11-27 17:06:22 +02:00
Tor Lillqvist 8dee781542 Use the right version name and git hash for the iOS app
Propagate the information to the otherwise pre-canned iOS version of
config.h, too.

Change-Id: Ia459a20b529e2ea02b4e00894521a085a8806d57
2018-11-27 01:05:04 +02:00
Tor Lillqvist a9f6d57222 Correct a few leftover mentions of "Mobile/Mobile" to "ios/Mobile"
Change-Id: Ie2e44bda495f3a08fc91c8d9fe40f9d1d9607283
2018-11-23 11:26:57 +02:00
Tor Lillqvist a6eadf4e81 Move the iOS app to the ios folder
Change-Id: I46e0722b027e93f90b5cd6a74cd7dc46f6c8cea2
2018-11-22 16:50:57 +02:00
Michael Meeks 4618b6c9c3 mobile: use more generic names to share with Android.
Change-Id: I747c6d384071d3a43d43c3c3f801efdfac0a1825
2018-11-22 14:11:59 +00:00
Andras Timar 51fdcdb424 configure: undefined option is "" not "no"
Change-Id: I39cba79aa98b7e0d13a53b37cba0833c5a5267a8
2018-11-07 12:39:47 +01:00
Tor Lillqvist 2c5893edfa Revert the addition of the --with-lo-srcdir option
Sadly, it did not work as expected. Even if the LibreOffice core
source that are mentioned in project.pbxproh, and referred to using
the losrcdir-symlink, did show up in Xcode, setting breakpoints in
them did not work. A pathname to such a source file would include
"losrcdir-symlink" which woul not match the pathname actually compiled
in the corresponding binary. Or something like that. So we are back at
requiring manual editing of the LO core source directory path in
project.pbxproj.

This commit reverts part of 5f2a6f6aa3.

Change-Id: I15fb7363e287fdf4942ac9d362a7151202d0ee9d
2018-11-04 12:58:30 +02:00
Tor Lillqvist e41ae35594 Differentiate the case of using --enable-iosapp on Linux from using it on macOS
On Linux, you use it just to process the JS bits, for copying them
over to the Mac where you build the app. (Because setting up npm and
whatnot on my Mac, from unknown 3rd parties, with unknown side
effects, semed a bit scary.)
2018-11-02 18:13:08 +02:00
Tor Lillqvist 5f2a6f6aa3 Avoid need for manual editing of the iOS app Xcode project file
Since some days, you need to run the configure script in a tree where
you are going to build the iOS app anyway (to set the app's
user-visible name). Use the configure script to set up a couple of
symbolic links pointing to the LibreOffice core source and build
directories and the Poco installation. Use those symbolic links in the
project file.

Also, now a vendor-specific app icon set can be given with the
--with-iosapp-appicon option.

Change-Id: Ib936388a4cc680bd97ca6ef95a91e3296ab04d18
2018-11-02 01:08:37 +02:00
Michael Meeks 52dace9d29 Disable SSL when configuring for mobile.
Change-Id: Ia337cde9f183849088d3712dd339f21b7d290fd7
2018-11-01 21:23:08 +00:00
Tor Lillqvist d5c5a17750 We can't use shell conditionals to decide whether to run m4 code or not
Put the definition of the PKG_CHECK_MODULES m4 macro (as empty, for
macOS) inside a m4_if that checks uname, not inside a shell if
statement.
2018-10-30 12:49:59 +02:00
Tor Lillqvist f7130f6d9c Fix shell if test syntax
Change-Id: I158befbd7d29e31be81e3d1b158fea574d72a2e5
2018-10-30 12:10:31 +02:00
Tor Lillqvist 0b49485383 Require running configure also in tree where you will build the iOS app
Take the user-visible name of the iOS app as a configure parameter
--with-iosapp-name. The only purpose of running the configure script
in this case is to get that expanded into the Info.plist file.

You need autofoo to build LibreOffice core for iOS anyway, so this
doesn't really add any new hurdles for a potential developer who wants
to build the iOS app

Bypass some checks that aren't relevant (and would fail) in this case.
Could bypass a lot more of configure.ac in the ENABLE_IOSAPP case.

Change-Id: Ia0cb82ad552da1bb597411748f0cd74f825774fa
2018-10-30 12:10:31 +02:00
Tor Lillqvist 89c8754225 Add gtk/README 2018-10-17 23:44:21 +03:00
Tor Lillqvist f122e92977 Build the GTK+ testbed app using autofoo
Rename the gtk/gtk.h file to gtk/gtk.hpp to not have it confused with
the actual GTK+ <gtk/gtk.h>.
2018-10-17 11:00:28 +03:00
Ashod Nakashian c93f98d8c4 configure: support disabling anonymization
And inform the user of the anonymization level.

Reviewed-on: https://gerrit.libreoffice.org/56567
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit 13f3b7848f)

Change-Id: I95cf832d5c4103744207214ffbf4e85d177ff190
2018-10-16 20:12:23 -04:00
Ashod Nakashian 87d442712e wsd: force anonymization when enabled with configure
This prevents disabling from loolwsd.xml when
the flags to anonymize are baked in at compile time.

Change-Id: If38ad3815bc9f18ed51b6626fc8c03528e7b8327
Reviewed-on: https://gerrit.libreoffice.org/56089
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
(cherry picked from commit 8844d238f1)
2018-10-16 20:12:23 -04:00
Ashod Nakashian b7f37af8f6 wsd: anonymization config and settings for username/filename
Change-Id: I9d7ce87b5f7d204b503d467959de008326b3411c
2018-10-16 20:12:23 -04:00
Ashod Nakashian 1e51b02db5 wsd: set SSL setting in loolwsd.xml based on configure --enable-ssl
Change-Id: I18f4c0cf4f5ec02a685d0721981a98396eb834fb
2018-10-16 20:12:23 -04:00
Tor Lillqvist fd758496a5 Add --enable-gtkapp configury option
Change-Id: Ib805581663aeec62d713f87ca72ab3cfe95db79f
2018-10-17 01:22:24 +03:00
Tor Lillqvist 1ae4a32067 Factor out loleaflet/dist construction for iOS app building
The idea is that on a Linux box you have a tree of online that you
configure with --enable-iosapp. Then running 'make' there will only
create the stuff in loleaflet/dist. That loleaflet/dist can then be
copied to the Mac where you build the iOS app.

(To me, this approach seemed for now simpler than to get all the
PKG_CONFIG etc stuff working that running configure normally requires,
and run all the node, npm, and associated crack, on a Mac.)

Change-Id: Id2e495d0521922d0666fdab5fdcb5fcd460136f1
2018-09-03 17:10:19 +03:00
Tor Lillqvist fc9f722a46 Revert "Look for libpng16, too, and link with -lz (in case static build)"
Nah. Let's not pretend. The configure script approach is for Linux
only.

This reverts commit db5a57308b.
2018-08-20 17:59:31 +03:00
Tor Lillqvist a035120095 Revert "Hopefully just 'readlink' (without the -f option) is enough"
Nah. Let's not pretend. The configure script approach is for Linux
only.

This reverts commit 574f769317.
2018-08-20 17:59:06 +03:00
Tor Lillqvist db5a57308b Look for libpng16, too, and link with -lz (in case static build) 2018-08-20 13:15:00 +03:00
Tor Lillqvist 574f769317 Hopefully just 'readlink' (without the -f option) is enough 2018-08-20 13:15:00 +03:00
Tor Lillqvist b811f70492 Revert "When asked to convert to PNG, look for an embedded ODF thumbnail first"
The embedded ODF thumbnail in documents produced by OOo or LO is too
small (max 256 pixels) to be useful in general, so let's not bother.

This reverts commit 3a9e536dfa.

Change-Id: I503b61f85264b9be658064632ffd1f94518b2a3c
2018-08-15 11:36:20 +03:00
Tor Lillqvist 3a9e536dfa When asked to convert to PNG, look for an embedded ODF thumbnail first
Change-Id: Ib777572fe5f79b1cfdd95ec3a7f84484a13ae145
2018-07-12 19:27:54 +03:00
Jan Holesovsky 06c978f0ef Don't confuse git wwhen the npm-shrinkwrap.json auto-updates.
Change-Id: I84e4d2b57b2b8db76935e33c28b2e99129b281c6
2018-05-18 15:49:07 +02:00
Henry Castro 8618885b31 use Makefile to build loleaflet
Concatenate and minify all javascript files in the release build but not
in the debug build. Also, it is enabled to use a build directory

Change-Id: Ia120447a827cfe236241ddf188bf43a088f877a7
Reviewed-on: https://gerrit.libreoffice.org/52802
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
2018-05-10 20:30:16 +02:00
Andras Timar 04feab241f use local tile cache directory for tests
Change-Id: I4c66a45df93bee22131c5950029cffa863d397b0
Reviewed-on: https://gerrit.libreoffice.org/54028
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2018-05-09 15:29:28 +02:00
Andras Timar 04539cc00c Revert "enable make parallelism"
Bad idea, 'make check' does not tolerate parallelism.

This reverts commit 2e4ecfaf44.
2018-03-09 12:49:02 +01:00
Miklos Vajna c54790def5 configure: require nodejs 6
Build will fail for nodejs 4 anyway, so fail early in configure.

Change-Id: I0be746454cd21401195f8bf72a4eb107a3433fd7
Reviewed-on: https://gerrit.libreoffice.org/50889
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2018-03-07 16:23:08 +01:00
Rene Engelhard 593c3b15f8 actually check for pam header and lib
Change-Id: Iaed84c3b72c2540176c8a0ed8e1f13d7c5cadc44
Reviewed-on: https://gerrit.libreoffice.org/50674
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2018-03-04 19:14:06 +01:00
Andras Timar 2e4ecfaf44 enable make parallelism
Change-Id: Ie16a450bee6d718d8daf58194fbbd7dfd1ac2f38
Reviewed-on: https://gerrit.libreoffice.org/50470
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2018-02-28 09:35:04 +01:00
Samuel Mehrbrodt 591a0b5fed Improve explanation for support key in configure
Change-Id: Ifd2fef9ff6b15e04e75bfecc478c3ac63efc84f5
Reviewed-on: https://gerrit.libreoffice.org/49672
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2018-02-15 09:16:18 +01:00
Miklos Vajna b8926baa18 configure: allow disable werror with --disable-werror
Change-Id: Ie614ce2143669008c38ecf4b267d6fec78337be6
Reviewed-on: https://gerrit.libreoffice.org/49434
Reviewed-by: Aron Budea <aron.budea@collabora.com>
Tested-by: Aron Budea <aron.budea@collabora.com>
2018-02-08 15:48:01 +01:00
Christian Glombek 51993b8990 Adds ENABLE_SETCAP build variable to avoid using env in build system.
Change-Id: Id38d2225238f8b3a48481a08e62cfa7544958cc9
Reviewed-on: https://gerrit.libreoffice.org/49097
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2018-02-04 22:27:09 +01:00
Pranav Kant 000e8a352c compilerplugins: pass absolute path to online dir
This makes plugin.so in core.git to enter in LOOL mode.

Change-Id: I99513b5a5b4e1ee2c26d16afa127b7a5da730ee3
2017-12-21 20:08:19 +05:30
Fabian Jucker 3b82f62084 correct help message for with-max-connections, with-max-documents
Change-Id: Ib7244a6ee55284b36d874a101505e2fe04377c9c
Reviewed-on: https://gerrit.libreoffice.org/43121
Reviewed-by: Fabian Jucker <jucker@gyselroth.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2017-11-20 10:14:45 +01:00
Tor Lillqvist 396c1488b4 Avoid test: : integer expression expected
Change-Id: I87f087a29ab4dc5cf94b0eee2a115b77c8283552
2017-10-26 16:56:25 +03:00
Jan Holesovsky 92aca7f2dd Compile the support key in (when configured to use one).
Change-Id: Iffff0b95b245b91d9732a774a6026a3cec2b2222
Reviewed-on: https://gerrit.libreoffice.org/43185
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
2017-10-06 11:39:29 +02:00
Jan Holesovsky 783e3552c0 Support key logic in loolws + improvements in loolconfig.
To be able to set the support key directly from the command line, and to show
the option, etc.

Change-Id: Iac93bc47a6f4b9d5a5ad0ac8b06bda978e01b760
Reviewed-on: https://gerrit.libreoffice.org/43098
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2017-10-06 11:37:18 +02:00
Michael Meeks 79053911fc Support key logic and verification.
Change-Id: Ie55150b99df3e80239236571af185502196ad3e9
Reviewed-on: https://gerrit.libreoffice.org/43097
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit 56385cb8ac)
Reviewed-on: https://gerrit.libreoffice.org/43099
2017-10-03 21:52:45 +02:00
Aron Budea 7455705517 Add dlopen check again to fix build
That unneeded dlopen check isn't unneeded.
Regression from 4be7a6cb16

Change-Id: I8fc451d16c3fa95696995d884743af675d42804d
Reviewed-on: https://gerrit.libreoffice.org/41077
Reviewed-by: Aron Budea <aron.budea@collabora.com>
Tested-by: Aron Budea <aron.budea@collabora.com>
2017-08-12 07:10:51 +02:00
Jan Holesovsky 4be7a6cb16 We don't need that new autoconf.
Also check for C++11 support, and remove an unneeded dlopen check (we check for
dlopen earlier in the configure.ac).

Change-Id: I76c25a25d22987ad6a1de309c3edd6ef2ea2b64d
Reviewed-on: https://gerrit.libreoffice.org/40952
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
2017-08-10 10:37:57 +02:00
Andras Timar 945d74c237 wsd: fix compilation with old OpenSSL that does not have PKCS5_PBKDF2_HMAC()
Change-Id: If48641f6cbcc4d4ded78ea5cc9c9f66063a2ac0a
Reviewed-on: https://gerrit.libreoffice.org/39779
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2017-07-31 19:40:37 +02:00
Andras Timar ad8bffa04a configure option to disable SECCOMP
Change-Id: I8120674b60d388a3f85190631469a112c4af9266
Reviewed-on: https://gerrit.libreoffice.org/39408
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
2017-07-03 11:43:01 +02:00
Jan Holesovsky 21192c4306 Generate the l10n json files only when the appropriate po's change.
Change-Id: I17c0f022775ec631e6493ba81fa41752f6841188
2017-05-05 11:28:26 +02:00
Michael Meeks 7f4f752667 Initial seccomp work.
Add a list of unhelpful looking system calls to improve containment.

Change-Id: I2e4bf3e0a6a752d427299728663d17120586bb10
2017-04-28 14:26:21 +01:00
Jan Holesovsky 848145503b Distribute the git hash for easier identification.
Change-Id: I57084231d0878de15b4b0478122f49e94af563bf
2017-04-28 11:54:38 +02:00
Katarina Behrens 6416fe9d1b Check if npm is installed and detect buggy version
shrinkpack won't work with npm versions between <3.9.0, 3.10.3>,
for details, see https://github.com/JamieMason/shrinkpack/issues/45

Change-Id: I65e1413f2ba24cc81736c12924afb20ca50004be
Reviewed-on: https://gerrit.libreoffice.org/36640
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
2017-04-19 16:19:58 +02:00
Katarina Behrens 8927eaf057 Strip trailing '/' from LO_PATH, if there's any
symlink() with path/with/trailing/slash/ and thus creating chroot
fails with ENOENT in totally opaque way

Change-Id: I5cd5213d8b6bfc50ea11cf8586b2a7b7f334631d
Reviewed-on: https://gerrit.libreoffice.org/36536
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2017-04-17 02:05:58 +02:00
Jan Holesovsky 37387518f4 Suppress assert()'s in the production builds.
Change-Id: I2074ed335b7201337e6519440ff6bed1809be915
2017-04-05 12:03:33 +02:00
Michael Meeks a4ac00d854 Add zlib cflags and libs to configuration. 2017-03-30 12:09:12 +01:00
Andras Timar 11fc3a0d02 package debian/ files and make them generic
Change-Id: Ia060b7d83c659db0354a5a1438b12bebaee45e03
2017-03-20 23:29:16 +01:00
Andras Timar 2828fc1684 no need for maketarballfordeb.sh any more
Change-Id: I18dd9e8fbd28431d49c67d40db521e0fdb6d3f27
2017-03-20 23:29:16 +01:00
Andras Timar 2cf1f22439 Use LO_PATH instead of hardcoded path as config default
Change-Id: I0d6ce9e7938e2521e764978526fe2d9ce632c992
2017-03-20 23:29:14 +01:00
Samuel Mehrbrodt 1f2d04a5e4 Online, not on-line
Change-Id: I93a8322dceca7c1ed95449c6aeb4ae854b982957
Reviewed-on: https://gerrit.libreoffice.org/33886
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2017-02-03 13:47:30 +00:00
Ashod Nakashian 78fdcb903a wsd: correct configuring MAX_DOCUMENTS
Change-Id: I14ffd990cdfb0206d93de01f42fc99efda4e6e8f
Reviewed-on: https://gerrit.libreoffice.org/33671
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2017-01-30 02:05:35 +00:00
Andras Timar f25f434be3 change version to 'master'
Change-Id: Ic842f811e86d3d910226fcd07ec44981917b8303
2017-01-09 21:17:25 +01:00
Pranav Kant 907b391f43 dist-hook and install-data-hook for loleaflet
Also tell automake to use tar-pax instead to allow bigger file
names (> 99).

Change-Id: I1d910a08684e780c958c7edc9852432705d51b18
2017-01-04 19:46:48 +05:30
Ashod Nakashian 3a79e13214 wsd: use MAX_CONNECTION from configure instead of hard-coded MAX_SESSIONS
Since we always need to set the thread-pool size
anyway, we cannot have 'unlimited' connections.

Actually, we never did, so that was misleading
in configure.ac anyway.

The current defaults are 20 connections and
10 documents, instead of the previous 1024
connections.
The reason for this "low" limit is to
enable unittesting these limits automatically
for the default configure.

There is also a lower-limit (needed by unittests
and internal technical requirements) of 3 connections
and 2 documents.

Change-Id: I6ccf3a607c50bb2a86bf1c0a16ebb6326ee34c7d
Reviewed-on: https://gerrit.libreoffice.org/32712
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2017-01-04 04:29:18 +00:00
Noel Grandin 4ed820d3d5 add a configure option for using clang compiler plugins
and apply the nullptr plugin.

Lots of hacking in my LO tree required to make this work, will probably
end up needing to add an extra parameter to the LO side.

Change-Id: I02ae1dcdece9d9ddf05f7757f6696e3a5d7d1f14
Reviewed-on: https://gerrit.libreoffice.org/32339
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
2016-12-22 14:23:42 +00:00
Pranav Kant 39dd5018e2 browser console logging depending on loleaflet_logging prop.
loleaflet_logging defaults to true with compiled with
--enable-debug otherwise false.

Browser will print additional debug info when this property is
set to true.

Change-Id: Id9fabf134bd8d19fa1a09ca8c0987df46d4f1a4c
2016-12-15 16:52:07 +05:30
Andras Timar 9ee4062935 Bump version to 2.0.1+
Change-Id: I1a670d3b9a3a5d3711f1a83b2a8978e032ded774
2016-12-14 11:34:11 +01:00
Pranav Kant b3db321e85 Unify loleaflet's make with top level make
Top level make would now build loleaflet too if necessary.

Respect value of ENABLE_DEBUG and if present add debug-info to
generated js bundles too.

Add new rule, clean-local in loleaflet.

Change-Id: I3a9b727824f2877fc72719a8bfdeebed5448cb7d
2016-12-12 17:56:58 +05:30
Andras Timar 740a28bfae Bump version to 2.0.0+ 2016-11-28 19:13:59 +01:00
Andras Timar 7a5fbd7f3c Bump version to 2.0.0 2016-11-28 19:10:27 +01:00
Michael Meeks c1a398977f Adapt makefiles, includes etc. to new locations. 2016-11-25 09:58:57 +00:00
Michael Meeks cca657c8f2 Apply the pre-branch rename script to re-organize the source. 2016-11-25 09:58:48 +00:00