Skip to contentSkip to conversation

tk: update the parameter for --with-tcl

PATCH New [email protected] 1 participant 2 messages Nov 14, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 tk: update the parameter for --with-tcl

From: Mingli Yu <[email protected]>

Update the parameter for --with-tcl to fix
below do_configure issue:

$ bitbake tk-native
| checking for Tcl configuration... configure: error: /mybuild/tmp/work/x86_64-linux/tk-native/8.6.8-r0/recipe-sysroot-native/usr/bin directory doesn't contain tclConfig.sh
---
 meta-oe/recipes-devtools/tcltk/tk_8.6.8.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta-oe/recipes-devtools/tcltk/tk_8.6.8.bb +1 -1
index 10281b2..d0f6fe0 100644
@@ -42,7 +42,7 @@ REQUIRED_DISTRO_FEATURES = "x11"
 EXTRA_OECONF = "\
     --enable-threads \
     --with-x \
-    --with-tcl=${STAGING_BINDIR_CROSS} \
+    --with-tcl=${STAGING_BINDIR}/crossscripts \
     --libdir=${libdir} \
 "
 
Signature · 1 line
2.7.4
#1 lore raw

PATCH 2/2 tk: export TK_LIBRARY='${libdir}/tk${VER}'

From: Mingli Yu <[email protected]>

As there is below logic in configure.in
[snip]
test -z "$TK_LIBRARY" && TK_LIBRARY='$(prefix)/lib/tk$(VERSION)' [snip]

It can make TK_LIBRARY to be $(prefix)/lib/tk$(VERSION) and then result in some files installed to
/usr/lib/tk8.6 even when ${libdir} actually
extract as /usr/lib64 and there is also a commit
as below adding hack to workaround this.
1ca29d1cd tk: make multilib build compatible and fix library install

Export TK_LIBRARY='${libdir}/tk${VER}' to guarantee the files installed to the expected places and also remove the workaround in the previous commit 1ca29d1cd.

---
 meta-oe/recipes-devtools/tcltk/tk_8.6.8.bb | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)
meta-oe/recipes-devtools/tcltk/tk_8.6.8.bb +1 -9
index d0f6fe0..4e38525 100644
@@ -45,19 +45,11 @@ EXTRA_OECONF = "\
     --with-tcl=${STAGING_BINDIR}/crossscripts \
     --libdir=${libdir} \
 "
-
+export TK_LIBRARY='${libdir}/tk${VER}'
 do_install_append() {
     ln -sf libtk${VER}.so ${D}${libdir}/libtk${VER}.so.0
     oe_libinstall -so libtk${VER} ${D}${libdir}
     ln -sf wish${VER} ${D}${bindir}/wish
-
-    # Even after passing libdir=${libdir} at config, some incorrect dirs are still generated for the multilib build
-    if [ "$libdir" != "/usr/lib" ]; then
-        # Move files to correct library directory
-        mv ${D}/usr/lib/tk${VER}/* ${D}/${libdir}/tk${VER}/
-        # Remove unneeded/incorrect dir ('usr/lib/')
-        rm -rf ${D}/usr/lib
-    fi
 }
 
 PACKAGECONFIG ??= "xft"
Signature · 1 line
2.7.4