[OE-core] [PATCH 13/30] external-sourcery: use ${prefix} and ${libdir} instead of /usr and /usr/lib

Javier Martinez Canillas javier at dowhile0.org
Sun Aug 5 15:54:00 UTC 2012


It is considered good practice to use the build system provided
variables instead of directly specify hardcoded paths.

Signed-off-by: Javier Martinez Canillas <javier at dowhile0.org>
---
 .../meta/external-sourcery-toolchain.bb            |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-core/meta/external-sourcery-toolchain.bb b/meta/recipes-core/meta/external-sourcery-toolchain.bb
index 74c82ec..18c3105 100644
--- a/meta/recipes-core/meta/external-sourcery-toolchain.bb
+++ b/meta/recipes-core/meta/external-sourcery-toolchain.bb
@@ -38,10 +38,10 @@ do_install() {
 	cp -a $sysroot/etc/. ${D}${sysconfdir}
 	cp -a $sysroot/sbin/. ${D}${base_sbindir}
 
-	install -d ${D}/usr
+	install -d ${D}${prefix}
 	for usr_element in bin libexec sbin share ${base_libdir}; do
 		usr_path=$sysroot/usr/$usr_element
-		cp -a $usr_path ${D}/usr/
+		cp -a $usr_path ${D}${prefix}/
 	done
 	for datadir_element in man info; do
 		datadir_path=$sysroot/usr/$datadir_element
@@ -81,7 +81,7 @@ external_toolchain_sysroot_adjust() {
 
 	# If the usr/lib directory doesn't exist, the toolchain fails to even
 	# try to find crti.o in a completely different directory (usr/lib64)
-	install -d ${SYSROOT_DESTDIR}/usr/lib
+	install -d ${SYSROOT_DESTDIR}${libdir}
 }
 
 PACKAGES =+ "libgcc libgcc-dev libstdc++ libstdc++-dev libstdc++-staticdev linux-libc-headers linux-libc-headers-dev gdbserver gdbserver-dbg"
-- 
1.7.7.6





More information about the Openembedded-core mailing list