From: Jiaying Song <[email protected]>

Modify the TCL_LIBRARY to the correct value to resolve the following errors 
caused by multilib:

application-specific initialization failed: Cannot find a usable init.tcl in 
the following directories:
    /usr/lib/tcl/ptest/library {} /usr/lib64/tcl9.0 /usr/lib64/tcl/lib/tcl9.0 
/usr/lib64/lib/tcl9.0 /usr/lib64/tcl/library /usr/lib64/library 
/usr/lib64/tcl9.0/library /usr/lib64/tcl9.0.0/library /usr/tcl9.0.0/library

Signed-off-by: Jiaying Song <[email protected]>
---
 meta/recipes-devtools/tcltk/tcl/run-ptest | 2 +-
 meta/recipes-devtools/tcltk/tcl_9.0.0.bb  | 2 ++
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/meta/recipes-devtools/tcltk/tcl/run-ptest 
b/meta/recipes-devtools/tcltk/tcl/run-ptest
index 8a9f611b0f..be067f13ea 100644
--- a/meta/recipes-devtools/tcltk/tcl/run-ptest
+++ b/meta/recipes-devtools/tcltk/tcl/run-ptest
@@ -1,6 +1,6 @@
 #!/bin/sh
 
-export TCL_LIBRARY=/usr/lib/tcl/ptest/library
+export TCL_LIBRARY=@libdir@/tcl/ptest/library
 export ERROR_ON_FAILURES=1
 export LANG=en-US.UTF-8
 
diff --git a/meta/recipes-devtools/tcltk/tcl_9.0.0.bb 
b/meta/recipes-devtools/tcltk/tcl_9.0.0.bb
index b67847c526..0d2efa44aa 100644
--- a/meta/recipes-devtools/tcltk/tcl_9.0.0.bb
+++ b/meta/recipes-devtools/tcltk/tcl_9.0.0.bb
@@ -82,6 +82,8 @@ do_install_ptest() {
        cp ${B}/tcltest ${D}${PTEST_PATH}
        cp -r ${S}/library ${D}${PTEST_PATH}
        cp -r ${S}/tests ${D}${PTEST_PATH}
+        # handle multilib
+        sed -i s:@libdir@:${libdir}:g ${D}${PTEST_PATH}/run-ptest
 }
 
 do_install_ptest:append:libc-musl () {
-- 
2.25.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#209055): 
https://lists.openembedded.org/g/openembedded-core/message/209055
Mute This Topic: https://lists.openembedded.org/mt/110267199/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to