Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] gcc-cross-intermediate: Ensure we move the libraries from the correct location
@ 2012-03-28 11:20 Richard Purdie
  0 siblings, 0 replies; only message in thread
From: Richard Purdie @ 2012-03-28 11:20 UTC (permalink / raw)
  To: openembedded-core

This fixes multilib issues if you try for example to use a BASELIB of /lib32
which wouldn't work without this change since the compiler install location
is taken from gcc -print-multi-os-directory which can still turn out to be
"/lib".

The reason is that a 32 bit gcc has no multilib code enabled and will always
return "." as that value rather than "../${base_libdir}" which our changes
to gcc enable and return in 64 bit mode.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
diff --git a/meta/recipes-devtools/gcc/gcc-cross-intermediate.inc b/meta/recipes-devtools/gcc/gcc-cross-intermediate.inc
index ea105e6..316a764 100644
--- a/meta/recipes-devtools/gcc/gcc-cross-intermediate.inc
+++ b/meta/recipes-devtools/gcc/gcc-cross-intermediate.inc
@@ -37,7 +37,8 @@ do_compile () {
 do_install () {
 	oe_runmake 'DESTDIR=${D}' install
 	install -d ${D}${target_base_libdir}/
-	mv ${D}${exec_prefix}/${TARGET_SYS}/${baselib}/* ${D}${target_base_libdir}/
+	osdir=`${D}${STAGING_BINDIR_TOOLCHAIN}.${PN}/${TARGET_PREFIX}gcc -print-multi-os-directory`
+	mv ${D}${exec_prefix}/${TARGET_SYS}/lib/$osdir/* ${D}${target_base_libdir}/
 
 	# We don't really need this (here shares/ contains man/, info/, locale/).
 	rm -rf ${D}${datadir}/





^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2012-03-28 11:29 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-28 11:20 [PATCH] gcc-cross-intermediate: Ensure we move the libraries from the correct location Richard Purdie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox