dev-libs/libpcre2: fix ld.lld symbol not defined (#973026)

remove local symbols to fix ld.ldd build errors:
- ld.lld: error: version script assignment of 'local' to symbol '_fini' failed: symbol not defined
- ld.lld: error: version script assignment of 'local' to symbol '_init' failed: symbol not defined

Upstream PR: https://github.com/PCRE2Project/pcre2/pull/884
Patch: https://github.com/termux/termux-packages/blob/master/packages/pcre2/0001-version-script-remove-local-symbols.patch

Closes: https://bugs.gentoo.org/973026
Signed-off-by: Pepper Gray <hello@peppergray.xyz>
Part-of: https://github.com/gentoo/gentoo/pull/46135
Closes: https://github.com/gentoo/gentoo/pull/46135
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Pepper Gray
2026-04-21 20:35:01 +02:00
committed by Sam James
parent 67dca78b6c
commit 6b667c68fb
2 changed files with 57 additions and 0 deletions

View File

@@ -0,0 +1,56 @@
# Gentoo Bug: https://bugs.gentoo.org/973026
# Upstream PR: https://github.com/PCRE2Project/pcre2/pull/884
# Patch: https://github.com/termux/termux-packages/blob/master/packages/pcre2/0001-version-script-remove-local-symbols.patch
#
# Fixes:
# ld.lld: error: version script assignment of 'local' to symbol '_fini' failed: symbol not defined
# ld.lld: error: version script assignment of 'local' to symbol '_init' failed: symbol not defined
--- a/src/libpcre2-16.sym
+++ b/src/libpcre2-16.sym
@@ -80,9 +80,6 @@
pcre2_substring_list_get_16;
pcre2_substring_nametable_scan_16;
pcre2_substring_number_from_name_16;
- local:
- _fini;
- _init;
};
# PCRE2_10.48 {} PCRE2_10.47;
--- a/src/libpcre2-32.sym
+++ b/src/libpcre2-32.sym
@@ -80,9 +80,6 @@
pcre2_substring_list_get_32;
pcre2_substring_nametable_scan_32;
pcre2_substring_number_from_name_32;
- local:
- _fini;
- _init;
};
# PCRE2_10.48 {} PCRE2_10.47;
--- a/src/libpcre2-8.sym
+++ b/src/libpcre2-8.sym
@@ -80,9 +80,6 @@
pcre2_substring_list_get_8;
pcre2_substring_nametable_scan_8;
pcre2_substring_number_from_name_8;
- local:
- _fini;
- _init;
};
# PCRE2_10.48 {} PCRE2_10.47;
--- a/src/libpcre2-posix.sym
+++ b/src/libpcre2-posix.sym
@@ -5,9 +5,6 @@
pcre2_regerror;
pcre2_regexec;
pcre2_regfree;
- local:
- _fini;
- _init;
};
# PCRE2_10.48 {} PCRE2_10.47;

View File

@@ -50,6 +50,7 @@ PATCHES=(
"${FILESDIR}"/${PN}-10.10-000-Fix-multilib.patch
"${FILESDIR}"/${PN}-10.47-riscv.patch
"${FILESDIR}"/${PN}-10.47-constness.patch
"${FILESDIR}"/${PN}-10.47-remove-local-symbols.patch
)
QA_CONFIG_IMPL_DECL_SKIP=(