diff mbox series

[meta-darwin,20/21] bash: link the in-tree readline on Darwin nativesdk

Message ID 20261014141209.488034-20-ecordonnier@snap.com
State New
Headers show
Series [meta-darwin,01/21] meta-darwin: bump layer series to wrynose (6.0.3) | expand

Commit Message

Etienne Cordonnier Oct. 14, 2026, 2:10 p.m. UTC
From: Etienne Cordonnier <ecordonnier@snap.com>

-lreadline resolves to the macOS SDK's libreadline.tbd stub, found via
the runtime/usr/lib -L path which precedes -L./lib/readline, instead of
the readline built in-tree. All rl_* symbols are then undefined at link
time. Link the in-tree archive by path.

Tested by building nativesdk-bash for x86_64-darwin.

AI-Generated: Claude Sonnet 5.5

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>
---
 recipes-extended/bash/bash_%.bbappend | 5 +++++
 1 file changed, 5 insertions(+)
 create mode 100644 recipes-extended/bash/bash_%.bbappend
diff mbox series

Patch

diff --git a/recipes-extended/bash/bash_%.bbappend b/recipes-extended/bash/bash_%.bbappend
new file mode 100644
index 0000000..31d46a6
--- /dev/null
+++ b/recipes-extended/bash/bash_%.bbappend
@@ -0,0 +1,5 @@ 
+# "-lreadline" resolves to the macOS SDK's libreadline.tbd stub (found via
+# the runtime/usr/lib -L path, which comes before -L./lib/readline) instead
+# of the readline built in-tree, which leaves all rl_* symbols undefined.
+# Link the in-tree archive by path.
+EXTRA_OEMAKE:append:darwin21 = " 'READLINE_LIB=$(READLINE_LIBRARY)'"