Skip to content

Commit

Permalink
editors/libreoffice: fix build with lld 17
Browse files Browse the repository at this point in the history
Building editors/libreoffice with lld 17 results in the following link
errors:

    ld: error: version script assignment of 'PRIVATE_1.4' to symbol '_ZN3sal13backtrace_getEm' failed: symbol not defined
    ld: error: version script assignment of 'GLIBCXX_3.4' to symbol '_ZNSs4_Rep20_S_empty_rep_storageE' failed: symbol not defined

Upstream fixed this only for Linux with:
LibreOffice/core@baddc74

Add the same block to the more generic unxgcc.mk makefile, so it gets
picked up for FreeBSD too.

PR:	274697
Author:    Dimitry Andric <dim@FreeBSD.org>
  • Loading branch information
DimitryAndric authored and fluffykhv committed Oct 24, 2023
1 parent 1ef5f13 commit 6338934
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions editors/libreoffice/files/patch-solenv_gbuild_platform_unxgcc.mk
@@ -1,6 +1,17 @@
--- solenv/gbuild/platform/unxgcc.mk.orig 2022-12-22 00:14:09 UTC
--- solenv/gbuild/platform/unxgcc.mk.orig 2023-09-22 19:07:01 UTC
+++ solenv/gbuild/platform/unxgcc.mk
@@ -55,8 +55,7 @@ gb_CXXFLAGS := \
@@ -17,6 +17,10 @@
# the License at http://www.apache.org/licenses/LICENSE-2.0 .
#

+ifneq ($(findstring lld,$(USE_LD)),)
+USE_LD += -Wl,--undefined-version
+endif
+
# to block heavy exception handling that try to acquire the solarmutex
export LO_LEAN_EXCEPTION=1

@@ -55,8 +59,7 @@ gb_CXXFLAGS := \
gb_CXXFLAGS := \
$(gb_CXXFLAGS_COMMON) \
-fPIC \
Expand Down

0 comments on commit 6338934

Please sign in to comment.