diff options
author | Tor Lillqvist <tml@collabora.com> | 2023-02-02 13:38:02 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@collabora.com> | 2023-02-02 11:52:58 +0000 |
commit | 6f6b879e8ddc689b5ffc245d641963557e3f3bca (patch) | |
tree | bac0d4fef6f47f90b0068bf599486df785901194 /static | |
parent | debd4cfa377f6895ecfe337216240bb7c581e84a (diff) |
Add instructions for when building headless LO core for WASM
Change-Id: Ic5fb943f8c26d21d94bafb815963960bdd2f26b9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/146497
Tested-by: Tor Lillqvist <tml@collabora.com>
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Diffstat (limited to 'static')
-rw-r--r-- | static/README.wasm.md | 39 |
1 files changed, 37 insertions, 2 deletions
diff --git a/static/README.wasm.md b/static/README.wasm.md index cbe5f74f6607..042417051de3 100644 --- a/static/README.wasm.md +++ b/static/README.wasm.md @@ -1,8 +1,19 @@ # Support for Emscripten Cross Build -This module provides support for emscripten cross build +This module provides support for building LibreOffice as WASM, with the Emscripten toolchain. -## Status +You can build LibreOffice core for WASM for two separate purposes: +Either to produce a WASM binary of LibreOffice as suchn, using Qt5 as +the GUI, or just compiling the LibreOffice code to WASM libraries +without any UI for use in other software that has the UI, like +Collabora Online. + +The first purpose was the original reason for the WASM port and this +document was originally written with that in mind. For the second +purpose, look towards the end of the document for the section +"Building headless LibreOffice as WASM for use in another product". + +## Status of LibreOffice as WASM with Qt The build generates a Writer-only LO build. You should be able to run either @@ -326,3 +337,27 @@ Emscripten supports standalone WASI binaries: - <https://emscripten.org/docs/introducing_emscripten/about_emscripten.html#about-emscripten-porting-code> - <https://emscripten.org/docs/compiling/Building-Projects.html> +## Building headless LibreOffice as WASM for use in another product + +### Set up Emscripten + +Follow the instructions in the first part of this document. + +### No Qt needed. + +You don't need any dependencies other than those that building LO normally downloads and compiled when building core. + +### Set up LO + +For instance, this autogen.input works for me: + +`--disable-debug` +`--enable-sal-log` +`--disable-crashdump` +`--host=wasm32-local-emscripten` +`--disable-gui` +`--with-main-module=writer` + +### That's all + +After all, in this case you are building LO core headless for it to be used by other software. |