git: 0f0ed642ede1 - 2024Q1 - net/jose: fix build with lld 18
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 27 Mar 2024 18:45:51 UTC
The branch 2024Q1 has been updated by dim:
URL: https://cgit.FreeBSD.org/ports/commit/?id=0f0ed642ede141994fc8b610ea6ee141ccc7c16a
commit 0f0ed642ede141994fc8b610ea6ee141ccc7c16a
Author: Dimitry Andric <dim@FreeBSD.org>
AuthorDate: 2024-03-21 13:31:57 +0000
Commit: Dimitry Andric <dim@FreeBSD.org>
CommitDate: 2024-03-27 18:45:35 +0000
net/jose: fix build with lld 18
With recent lld, the --version-script check in net/jose's meson.build
fails, causing it to erroneously use a -export-symbols-regex flag:
cc: error: unknown argument: '-export-symbols-regex=^jose_.*'
Fix this by adding --undefined-version to the meson check, so it
succeeds.
PR: 277905
Approved by: hdholm@alumni.iastate.edu (maintainer)
MFH: 2024Q1
(cherry picked from commit 142d074b14d2f69452f2468d801d9f5e0d2669ef)
---
net/jose/files/patch-lib_meson.build | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/net/jose/files/patch-lib_meson.build b/net/jose/files/patch-lib_meson.build
new file mode 100644
index 000000000000..18e6c42b2118
--- /dev/null
+++ b/net/jose/files/patch-lib_meson.build
@@ -0,0 +1,10 @@
+--- lib/meson.build.orig 2024-02-02 10:53:08 UTC
++++ lib/meson.build
+@@ -2,7 +2,7 @@ flags = '-Wl,--version-script=' + meson.current_source_dir() + '/libjose.map'
+ code = 'int main() { return 0; }'
+ cc = meson.get_compiler('c')
+
+-if not cc.links(code, args: flags, name: '-Wl,--version-script=...')
++if not cc.links(code, args: flags + ',--undefined-version' , name: '-Wl, --version-script=...')
+ flags = [ '-export-symbols-regex=^jose_.*' ]
+ endif