Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 6 Oct 2023 17:50:58 GMT
From:      Dimitry Andric <dim@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: 623262a13efb - main - devel/libnotify: fix build with lld 17
Message-ID:  <202310061750.396HowH7039331@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by dim:

URL: https://cgit.FreeBSD.org/ports/commit/?id=623262a13efb4c659fda87783fb5e6164c24a774

commit 623262a13efb4c659fda87783fb5e6164c24a774
Author:     Dimitry Andric <dim@FreeBSD.org>
AuthorDate: 2023-09-26 14:19:09 +0000
Commit:     Dimitry Andric <dim@FreeBSD.org>
CommitDate: 2023-10-06 17:48:54 +0000

    devel/libnotify: fix build with lld 17
    
    Building devel/libnotify with lld 17 results in the following link
    error:
    
      cc  -o libnotify/libnotify.so.4.0.0 libnotify/libnotify.so.4.0.0.p/meson-generated_.._notify-enum-types.c.o libnotify/libnotify.so.4.0.0.p/meson-generated_.._notify-marshal.c.o libnotify/libnotify.so.4.0.0.p/notify.c.o libnotify/libnotify.so.4.0.0.p/notification.c.o -Wl,--as-needed -Wl,--no-undefined -Wl,-O1 -shared -fPIC -Wl,--start-group -Wl,-soname,libnotify.so.4 -fstack-protector-strong -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -Wl,-rpath,/usr/local/lib -Wl,-rpath-link,/usr/local/lib -Wl,--version-script,/wrkdirs/share/dim/ports/devel/libnotify/work/libnotify-0.8.2/libnotify/libnotify.map /usr/local/lib/libgdk_pixbuf-2.0.so /usr/local/lib/libgobject-2.0.so /usr/local/lib/libglib-2.0.so /usr/local/lib/libintl.so /usr/local/lib/libgio-2.0.so -Wl,--end-group
      ld: error: version script assignment of 'global' to symbol '__progname' failed: symbol not defined
      ld: error: version script assignment of 'global' to symbol 'environ' failed: symbol not defined
      cc: error: linker command failed with exit code 1 (use -v to see invocation)
    
    This is because lld 17 defaults to errors when undefined symbols are
    referenced in linker version scripts.
    
    Apparently the __progname and environ symbols (which usually come from
    libc, not libnotify.so) were explicitly added in:
    
    commit 0b0b10cff8d7b5ed08d11c6fa4d66e1977d6eb79
    Author: Baptiste Daroussin <bapt@FreeBSD.org>
    Date:   2019-12-16T19:40:37+01:00
    
        Fix build with old binutils.
    
        Somehow linker scripts should not hide __progname and environ from symbols.
    
        Reported by:    kib
    
    but it is unclear what the original error was, or how old "old" is, and
    there is no reference to a PR.
    
    In any case, I think the patch-libnotify_libnotify.map file can simply
    be deleted now.
    
    PR:             274108
    Approved by:    maintainer timeout (10 days)
    MFH:            2023Q4
---
 devel/libnotify/files/patch-libnotify_libnotify.map | 11 -----------
 1 file changed, 11 deletions(-)

diff --git a/devel/libnotify/files/patch-libnotify_libnotify.map b/devel/libnotify/files/patch-libnotify_libnotify.map
deleted file mode 100644
index bdc318de8dec..000000000000
--- a/devel/libnotify/files/patch-libnotify_libnotify.map
+++ /dev/null
@@ -1,11 +0,0 @@
---- libnotify/libnotify.map.orig	2019-04-05 19:06:19 UTC
-+++ libnotify/libnotify.map
-@@ -1,6 +1,8 @@
- {
- global:
-     notify_*;
-+    __progname;
-+    environ;
- local:
-     *;
- };



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202310061750.396HowH7039331>