config_host.mk.in                 |    1 +
 configure.ac                      |    1 +
 desktop/Executable_soffice_bin.mk |    6 ++++++
 3 files changed, 8 insertions(+)

New commits:
commit 82640810efd1636e358c047a1a5b3e4e3fc9d28a
Author:     Stephan Bergmann <stephan.bergm...@allotropia.de>
AuthorDate: Fri Jun 7 12:19:52 2024 +0200
Commit:     Stephan Bergmann <stephan.bergm...@allotropia.de>
CommitDate: Fri Jun 7 13:30:31 2024 +0200

    New EMSCRIPTEN_EXTRA_SOFFICE_POST_JS configure variable
    
    ...which can be useful during development, to add e.g. additional test code 
to
    the generated qt_soffice.html
    
    Change-Id: Ic498dcd4c812b7b4c8e48b07c2bff411a9f19438
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168522
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <stephan.bergm...@allotropia.de>

diff --git a/config_host.mk.in b/config_host.mk.in
index 334d9fd53f16..a3a965364750 100644
--- a/config_host.mk.in
+++ b/config_host.mk.in
@@ -143,6 +143,7 @@ export DPKG=@DPKG@
 export EBOOK_CFLAGS=$(gb_SPACE)@EBOOK_CFLAGS@
 export EBOOK_LIBS=$(gb_SPACE)@EBOOK_LIBS@
 export EMSDK_FILE_PACKAGER=@EMSDK_FILE_PACKAGER@
+export EMSCRIPTEN_EXTRA_SOFFICE_POST_JS=@EMSCRIPTEN_EXTRA_SOFFICE_POST_JS@
 export ENABLE_ANDROID_LOK=@ENABLE_ANDROID_LOK@
 export ENABLE_ANDROID_EDITING=@ENABLE_ANDROID_EDITING@
 export ENABLE_AVAHI=@ENABLE_AVAHI@
diff --git a/configure.ac b/configure.ac
index 3f9805e4ff82..1fe2a15ca366 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1485,6 +1485,7 @@ if test "$_os" = "Emscripten"; then
     BUILD_TYPE="$BUILD_TYPE EMSCRIPTEN"
 fi
 AC_SUBST(EMSDK_FILE_PACKAGER)
+AC_SUBST(EMSCRIPTEN_EXTRA_SOFFICE_POST_JS)
 
 ###############################################################################
 # Extensions switches --enable/--disable
diff --git a/desktop/Executable_soffice_bin.mk 
b/desktop/Executable_soffice_bin.mk
index 0d3ac520c398..b9ce457abbc0 100644
--- a/desktop/Executable_soffice_bin.mk
+++ b/desktop/Executable_soffice_bin.mk
@@ -84,6 +84,12 @@ $(eval $(call gb_Executable_add_ldflags,soffice_bin, \
 
 endif
 
+$(call gb_Executable_get_linktarget_target,soffice_bin): 
$(EMSCRIPTEN_EXTRA_SOFFICE_POST_JS)
+
+$(eval $(call gb_Executable_add_ldflags,soffice_bin, \
+    $(foreach i,$(EMSCRIPTEN_EXTRA_SOFFICE_POST_JS),--post-js $(i)) \
+))
+
 endif
 
 # vim: set ts=4 sw=4 et:

Reply via email to