Skip to contentSkip to conversation

Remove CROSS_DIR, install cross-packages into native sysroot

RFC PATCH In review Khem Raj 9 participants 35 messages Jul 21, 2010 – Jul 24, 2010

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

cover Remove CROSS_DIR, install cross-packages into native sysroot

Hi

The following 4 patches are based on Jushua's work in poky to get rid of cross dir and install the toolchain in native sysroot.

I have done native-sdk-builds for uclibc and eglibc. It could build the images and the images booted fine in qemu on mips and arm.

I would appreciate if someone could lend a hand in testing these patches

And as we have changed tmpdir layout with this patch I have also bumped ABI which means tmp has to be nuked before you try these patches.

Please review/ack/nack

Thanks
-Khem

author
#1 lore raw

PATCH 1/4 classes, bitbake.conf: Remove CROSS_DIR, install cross-packages into native sysroot

* Update references to CROSS_DIR in classes and bitbake.conf.
* This patch is based on Joshua Lock's work in poky.

---
 classes/cmake.bbclass            |    2 +-
 classes/cross.bbclass            |    8 ++++----
 classes/glibc-package.bbclass    |    8 ++++----
 classes/icecc.bbclass            |    6 +++---
 classes/nativesdk.bbclass        |    2 --
 classes/packaged-staging.bbclass |    5 -----
 conf/bitbake.conf                |    7 ++-----
 7 files changed, 14 insertions(+), 24 deletions(-)
classes/cmake.bbclass +1 -1
index 2047b58..2376012 100644
@@ -37,7 +37,7 @@ cmake_do_generate_toolchain_file() {
 
 # only search in the paths provided (from openembedded) so cmake doesnt pick
 # up libraries and tools from the native build machine
-  echo "set( CMAKE_FIND_ROOT_PATH ${STAGING_DIR_HOST} ${STAGING_DIR_NATIVE} ${CROSS_DIR} )" >> ${WORKDIR}/toolchain.cmake
+  echo "set( CMAKE_FIND_ROOT_PATH ${STAGING_DIR_HOST} ${STAGING_DIR_NATIVE} ${STAGING_DIR_NATIVE}${prefix_native} )" >> ${WORKDIR}/toolchain.cmake
   echo "set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM ONLY )" >> ${WORKDIR}/toolchain.cmake
   echo "set( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY )" >> ${WORKDIR}/toolchain.cmake
   echo "set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY )" >> ${WORKDIR}/toolchain.cmake
classes/cross.bbclass +4 -4
index 4cf2b4c..75b2abe 100644
@@ -1,5 +1,5 @@
 # Disabled for now since the relocation paths are too long
-#inherit relocatable
+inherit relocatable
 
 # Cross packages are built indirectly via dependency,
 # no need for them to be a direct target of 'world'
@@ -44,9 +44,9 @@ target_base_libdir := "${base_libdir}"
 target_prefix := "${prefix}"
 
 # Overrides for paths
-prefix = "${CROSS_DIR}"
-base_prefix = "${prefix}"
-exec_prefix = "${prefix}"
+prefix = "${STAGING_DIR_NATIVE}${prefix_native}"
+base_prefix = "${STAGING_DIR_NATIVE}"
+exec_prefix = "${STAGING_DIR_NATIVE}${prefix_native}"
 base_sbindir = "${base_prefix}/bin"
 sbindir = "${exec_prefix}/bin"
 
classes/glibc-package.bbclass +4 -4
index d47c914..36424d5 100644
@@ -104,11 +104,11 @@ do_prep_locale_tree() {
 		gunzip $i
 	done
 	ls -d ${PKGD}${base_libdir}/* | xargs -iBLAH cp -pPR BLAH $treedir/lib
-	if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so ]; then
-		cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so $treedir/lib
+	if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/lib/libgcc_s.so ]; then
+		cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/lib/libgcc_s.so $treedir/lib
 	fi
-	if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.* ]; then
-		cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.* $treedir/lib
+	if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/lib/libgcc_s.so.* ]; then
+		cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/lib/libgcc_s.so.* $treedir/lib
 	fi
 	install -m 0755 ${PKGD}${bindir}/localedef $treedir/bin
 }
classes/icecc.bbclass +3 -3
index 36cc231..938f199 100644
@@ -46,7 +46,7 @@ def create_cross_env(bb,d):
         return ""
 
     import tarfile, socket, time
-    ice_dir = bb.data.expand('${CROSS_DIR}', d)
+    ice_dir = bb.data.expand('${STAGING_DIR_NATIVE}${prefix_native}', d)
     staging_dir = bb.data.expand('${STAGING_DIR_TARGET}', d)
     prefix  = bb.data.expand('${HOST_PREFIX}' , d)
     distro  = bb.data.expand('${DISTRO}', d)
@@ -96,7 +96,7 @@ def create_cross_env(bb,d):
 
 def create_native_env(bb,d):
     import tarfile, socket, time
-    ice_dir = bb.data.expand('${CROSS_DIR}', d)
+    ice_dir = bb.data.expand('${STAGING_DIR_NATIVE}${prefix_native}', d)
     prefix  = bb.data.expand('${HOST_PREFIX}' , d)
     distro  = bb.data.expand('${DISTRO}', d)
     target_sys = bb.data.expand('${TARGET_SYS}',  d)
@@ -143,7 +143,7 @@ def get_cross_kernel_cc(bb,d):
 
 def create_cross_kernel_env(bb,d):
     import tarfile, socket, time
-    ice_dir = bb.data.expand('${CROSS_DIR}', d)
+    ice_dir = bb.data.expand('${STAGING_DIR_NATIVE}${prefix_native}', d)
     prefix  = bb.data.expand('${HOST_PREFIX}' , d)
     distro  = bb.data.expand('${DISTRO}', d)
     target_sys = bb.data.expand('${TARGET_SYS}',  d)
classes/nativesdk.bbclass +0 -2
index 75f5790..ddaab85 100644
@@ -18,8 +18,6 @@ python () {
 #STAGING_DIR_HOST = "${STAGING_DIR}/${HOST_SYS}-nativesdk"
 #STAGING_DIR_TARGET = "${STAGING_DIR}/${BASEPKG_TARGET_SYS}-nativesdk"
 
-CROSS_DIR = "${TMPDIR}/cross/${HOST_ARCH}"
-
 HOST_ARCH = "${SDK_ARCH}"
 HOST_VENDOR = "${SDK_VENDOR}"
 HOST_OS = "${SDK_OS}"
classes/packaged-staging.bbclass +0 -5
index 670fd1c..fda1431 100644
@@ -130,7 +130,6 @@ def pstage_cleanpackage(pkgname, d):
 	else:
 		bb.debug(1, "Manually removing any installed files from staging...")
 		pstage_manualclean("sysroots", "STAGING_DIR", d)
-		pstage_manualclean("cross", "CROSS_DIR", d)
 		pstage_manualclean("deploy", "DEPLOY_DIR", d)
 
 	bb.utils.unlockfile(lf)
@@ -307,7 +306,6 @@ python packagedstage_stampfixing_eventhandler() {
 populate_sysroot_preamble () {
 	if [ "$PSTAGING_ACTIVE" = "1" ]; then
 		stage-manager -p ${STAGING_DIR} -c ${PSTAGE_WORKDIR}/stamp-cache-staging -u || true
-		stage-manager -p ${CROSS_DIR} -c ${PSTAGE_WORKDIR}/stamp-cache-cross -u || true
 	fi
 }
 
@@ -323,7 +321,6 @@ populate_sysroot_postamble () {
 		if [ "$exitcode" != "5" -a "$exitcode" != "0" ]; then
 			exit $exitcode
 		fi
-		stage-manager -p ${CROSS_DIR} -c ${PSTAGE_WORKDIR}/stamp-cache-cross -u -d ${PSTAGE_TMPDIR_STAGE}/cross/${BASE_PACKAGE_ARCH}
 		if [ "$exitcode" != "5" -a "$exitcode" != "0" ]; then
 			exit $exitcode
 		fi
@@ -334,9 +331,7 @@ populate_sysroot_postamble () {
 packagedstaging_fastpath () {
 	if [ "$PSTAGING_ACTIVE" = "1" ]; then
 		mkdir -p ${PSTAGE_TMPDIR_STAGE}/sysroots/
-		mkdir -p ${PSTAGE_TMPDIR_STAGE}/cross/${BASE_PACKAGE_ARCH}/
 		cp -fpPR ${SYSROOT_DESTDIR}/${STAGING_DIR}/* ${PSTAGE_TMPDIR_STAGE}/sysroots/ || /bin/true
-		cp -fpPR ${SYSROOT_DESTDIR}/${CROSS_DIR}/* ${PSTAGE_TMPDIR_STAGE}/cross/${BASE_PACKAGE_ARCH}/ || /bin/true
 	fi
 }
 
conf/bitbake.conf +2 -5
index 69d00e2..748abba 100644
@@ -410,10 +410,7 @@ EXTRA_IMAGEDEPENDS = ""
 ##################################################################
 # Toolchain info.
 ##################################################################
-
-CROSS_DIR = "${TMPDIR}/cross/${BASE_PACKAGE_ARCH}"
-CROSS_DATADIR = "${CROSS_DIR}/share"
-PATH_prepend = "${STAGING_BINDIR_CROSS}:${STAGING_BINDIR_CROSS_BASEPKG}:${STAGING_SBINDIR_NATIVE}:${STAGING_BINDIR_NATIVE}:${CROSS_DIR}/${bindir_cross}:${STAGING_DIR_NATIVE}${base_sbindir_native}:${STAGING_DIR_NATIVE}${base_bindir_native}:"
+PATH_prepend = "${STAGING_BINDIR_CROSS}:${STAGING_DIR_NATIVE}${sbindir_native}:${STAGING_BINDIR_NATIVE}:${STAGING_DIR_NATIVE}${base_sbindir_native}:${STAGING_DIR_NATIVE}/${base_bindir_native}:"
 export PATH
 
 ##################################################################
@@ -422,7 +419,7 @@ export PATH
 
 CCACHE ?= ""
 TOOLCHAIN_OPTIONS = ""
-TOOLCHAIN_PATH ?= "${CROSS_DIR}"
+TOOLCHAIN_PATH ?= "${STAGING_DIR_NATIVE}${prefix_native}"
 TOOLCHAIN_SYSPATH ?= "${TOOLCHAIN_PATH}/${TARGET_SYS}"
 
 export CC = "${CCACHE}${HOST_PREFIX}gcc ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
Signature · 1 line
1.7.1
Acked-by on v1 1/4
#2 lore raw

Re: [PATCH 1/4] classes, bitbake.conf: Remove CROSS_DIR, install cross-packages into native sysroot

Quoted 4 lines · Khem Raj

* Update references to CROSS_DIR in classes and bitbake.conf.
* This patch is based on Joshua Lock's work in poky.

Quoted 174 lines
---
 classes/cmake.bbclass            |    2 +-
 classes/cross.bbclass            |    8 ++++----
 classes/glibc-package.bbclass    |    8 ++++----
 classes/icecc.bbclass            |    6 +++---
 classes/nativesdk.bbclass        |    2 --
 classes/packaged-staging.bbclass |    5 -----
 conf/bitbake.conf                |    7 ++-----
 7 files changed, 14 insertions(+), 24 deletions(-)
classes/cmake.bbclass +1 -1
index 2047b58..2376012 100644
@@ -37,7 +37,7 @@ cmake_do_generate_toolchain_file() {
 
 # only search in the paths provided (from openembedded) so cmake doesnt pick
 # up libraries and tools from the native build machine
-  echo "set( CMAKE_FIND_ROOT_PATH ${STAGING_DIR_HOST} ${STAGING_DIR_NATIVE} ${CROSS_DIR} )" >> ${WORKDIR}/toolchain.cmake
+  echo "set( CMAKE_FIND_ROOT_PATH ${STAGING_DIR_HOST} ${STAGING_DIR_NATIVE} ${STAGING_DIR_NATIVE}${prefix_native} )" >> ${WORKDIR}/toolchain.cmake
   echo "set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM ONLY )" >> ${WORKDIR}/toolchain.cmake
   echo "set( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY )" >> ${WORKDIR}/toolchain.cmake
   echo "set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY )" >> ${WORKDIR}/toolchain.cmake
classes/cross.bbclass +4 -4
index 4cf2b4c..75b2abe 100644
@@ -1,5 +1,5 @@
 # Disabled for now since the relocation paths are too long
-#inherit relocatable
+inherit relocatable
 
 # Cross packages are built indirectly via dependency,
 # no need for them to be a direct target of 'world'
@@ -44,9 +44,9 @@ target_base_libdir := "${base_libdir}"
 target_prefix := "${prefix}"
 
 # Overrides for paths
-prefix = "${CROSS_DIR}"
-base_prefix = "${prefix}"
-exec_prefix = "${prefix}"
+prefix = "${STAGING_DIR_NATIVE}${prefix_native}"
+base_prefix = "${STAGING_DIR_NATIVE}"
+exec_prefix = "${STAGING_DIR_NATIVE}${prefix_native}"
 base_sbindir = "${base_prefix}/bin"
 sbindir = "${exec_prefix}/bin"
 
classes/glibc-package.bbclass +4 -4
index d47c914..36424d5 100644
@@ -104,11 +104,11 @@ do_prep_locale_tree() {
 		gunzip $i
 	done
 	ls -d ${PKGD}${base_libdir}/* | xargs -iBLAH cp -pPR BLAH $treedir/lib
-	if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so ]; then
-		cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so $treedir/lib
+	if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/lib/libgcc_s.so ]; then
+		cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/lib/libgcc_s.so $treedir/lib
 	fi
-	if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.* ]; then
-		cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.* $treedir/lib
+	if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/lib/libgcc_s.so.* ]; then
+		cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/lib/libgcc_s.so.* $treedir/lib
 	fi
 	install -m 0755 ${PKGD}${bindir}/localedef $treedir/bin
 }
classes/icecc.bbclass +3 -3
index 36cc231..938f199 100644
@@ -46,7 +46,7 @@ def create_cross_env(bb,d):
         return ""
 
     import tarfile, socket, time
-    ice_dir = bb.data.expand('${CROSS_DIR}', d)
+    ice_dir = bb.data.expand('${STAGING_DIR_NATIVE}${prefix_native}', d)
     staging_dir = bb.data.expand('${STAGING_DIR_TARGET}', d)
     prefix  = bb.data.expand('${HOST_PREFIX}' , d)
     distro  = bb.data.expand('${DISTRO}', d)
@@ -96,7 +96,7 @@ def create_cross_env(bb,d):
 
 def create_native_env(bb,d):
     import tarfile, socket, time
-    ice_dir = bb.data.expand('${CROSS_DIR}', d)
+    ice_dir = bb.data.expand('${STAGING_DIR_NATIVE}${prefix_native}', d)
     prefix  = bb.data.expand('${HOST_PREFIX}' , d)
     distro  = bb.data.expand('${DISTRO}', d)
     target_sys = bb.data.expand('${TARGET_SYS}',  d)
@@ -143,7 +143,7 @@ def get_cross_kernel_cc(bb,d):
 
 def create_cross_kernel_env(bb,d):
     import tarfile, socket, time
-    ice_dir = bb.data.expand('${CROSS_DIR}', d)
+    ice_dir = bb.data.expand('${STAGING_DIR_NATIVE}${prefix_native}', d)
     prefix  = bb.data.expand('${HOST_PREFIX}' , d)
     distro  = bb.data.expand('${DISTRO}', d)
     target_sys = bb.data.expand('${TARGET_SYS}',  d)
classes/nativesdk.bbclass +0 -2
index 75f5790..ddaab85 100644
@@ -18,8 +18,6 @@ python () {
 #STAGING_DIR_HOST = "${STAGING_DIR}/${HOST_SYS}-nativesdk"
 #STAGING_DIR_TARGET = "${STAGING_DIR}/${BASEPKG_TARGET_SYS}-nativesdk"
 
-CROSS_DIR = "${TMPDIR}/cross/${HOST_ARCH}"
-
 HOST_ARCH = "${SDK_ARCH}"
 HOST_VENDOR = "${SDK_VENDOR}"
 HOST_OS = "${SDK_OS}"
classes/packaged-staging.bbclass +0 -5
index 670fd1c..fda1431 100644
@@ -130,7 +130,6 @@ def pstage_cleanpackage(pkgname, d):
 	else:
 		bb.debug(1, "Manually removing any installed files from staging...")
 		pstage_manualclean("sysroots", "STAGING_DIR", d)
-		pstage_manualclean("cross", "CROSS_DIR", d)
 		pstage_manualclean("deploy", "DEPLOY_DIR", d)
 
 	bb.utils.unlockfile(lf)
@@ -307,7 +306,6 @@ python packagedstage_stampfixing_eventhandler() {
 populate_sysroot_preamble () {
 	if [ "$PSTAGING_ACTIVE" = "1" ]; then
 		stage-manager -p ${STAGING_DIR} -c ${PSTAGE_WORKDIR}/stamp-cache-staging -u || true
-		stage-manager -p ${CROSS_DIR} -c ${PSTAGE_WORKDIR}/stamp-cache-cross -u || true
 	fi
 }
 
@@ -323,7 +321,6 @@ populate_sysroot_postamble () {
 		if [ "$exitcode" != "5" -a "$exitcode" != "0" ]; then
 			exit $exitcode
 		fi
-		stage-manager -p ${CROSS_DIR} -c ${PSTAGE_WORKDIR}/stamp-cache-cross -u -d ${PSTAGE_TMPDIR_STAGE}/cross/${BASE_PACKAGE_ARCH}
 		if [ "$exitcode" != "5" -a "$exitcode" != "0" ]; then
 			exit $exitcode
 		fi
@@ -334,9 +331,7 @@ populate_sysroot_postamble () {
 packagedstaging_fastpath () {
 	if [ "$PSTAGING_ACTIVE" = "1" ]; then
 		mkdir -p ${PSTAGE_TMPDIR_STAGE}/sysroots/
-		mkdir -p ${PSTAGE_TMPDIR_STAGE}/cross/${BASE_PACKAGE_ARCH}/
 		cp -fpPR ${SYSROOT_DESTDIR}/${STAGING_DIR}/* ${PSTAGE_TMPDIR_STAGE}/sysroots/ || /bin/true
-		cp -fpPR ${SYSROOT_DESTDIR}/${CROSS_DIR}/* ${PSTAGE_TMPDIR_STAGE}/cross/${BASE_PACKAGE_ARCH}/ || /bin/true
 	fi
 }
 
conf/bitbake.conf +2 -5
index 69d00e2..748abba 100644
@@ -410,10 +410,7 @@ EXTRA_IMAGEDEPENDS = ""
 ##################################################################
 # Toolchain info.
 ##################################################################
-
-CROSS_DIR = "${TMPDIR}/cross/${BASE_PACKAGE_ARCH}"
-CROSS_DATADIR = "${CROSS_DIR}/share"
-PATH_prepend = "${STAGING_BINDIR_CROSS}:${STAGING_BINDIR_CROSS_BASEPKG}:${STAGING_SBINDIR_NATIVE}:${STAGING_BINDIR_NATIVE}:${CROSS_DIR}/${bindir_cross}:${STAGING_DIR_NATIVE}${base_sbindir_native}:${STAGING_DIR_NATIVE}${base_bindir_native}:"
+PATH_prepend = "${STAGING_BINDIR_CROSS}:${STAGING_DIR_NATIVE}${sbindir_native}:${STAGING_BINDIR_NATIVE}:${STAGING_DIR_NATIVE}${base_sbindir_native}:${STAGING_DIR_NATIVE}/${base_bindir_native}:"
 export PATH
 
 ##################################################################
@@ -422,7 +419,7 @@ export PATH
 
 CCACHE ?= ""
 TOOLCHAIN_OPTIONS = ""
-TOOLCHAIN_PATH ?= "${CROSS_DIR}"
+TOOLCHAIN_PATH ?= "${STAGING_DIR_NATIVE}${prefix_native}"
 TOOLCHAIN_SYSPATH ?= "${TOOLCHAIN_PATH}/${TARGET_SYS}"
 
 export CC = "${CCACHE}${HOST_PREFIX}gcc ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
Signature · 2 lines
Tom Rini
Mentor Graphics Corporation
author
#3 lore raw

PATCH 2/4 toolchain: Remove references to CROSS_DIR

In reply to Khem Raj

* Toolchain is installed into native sysroot now.

---
 recipes/binutils/binutils-cross.inc                |   20 +++++++++---------
 recipes/eglibc/eglibc-package.bbclass              |    4 +-
 recipes/gcc/gcc-configure-sdk.inc                  |   22 ++++++++++----------
 recipes/gcc/gcc-cross-initial_csl-arm-2007q3.bb    |    4 +-
 .../gcc/gcc-cross-intermediate_csl-arm-2007q3.bb   |    4 +-
 recipes/gcc/gcc-cross-kernel.inc                   |    2 +-
 recipes/gcc/gcc-cross-sdk_3.4.4.bb                 |    4 +-
 recipes/gcc/gcc-cross_csl-arm-2007q3.bb            |    6 ++--
 recipes/gcc/gcc-cross_csl-arm-2008q1.bb            |    6 ++--
 recipes/gcc/gcc-cross_csl-arm-2008q3.bb            |    6 ++--
 recipes/gcc/gcc-package-cross.inc                  |    8 +++---
 11 files changed, 43 insertions(+), 43 deletions(-)
recipes/binutils/binutils-cross.inc +10 -10
index 432e1a7..f3ba5c3 100644
@@ -16,14 +16,14 @@ do_install () {
 	${D}${libdir}/libiberty_pic.a
 
 	# We don't really need these, so we'll remove them...
-	rm -rf ${D}${CROSS_DIR}/lib/ldscripts
-	rm -rf ${D}${CROSS_DIR}/share/info
-	rm -rf ${D}${CROSS_DIR}/share/locale
-	rm -rf ${D}${CROSS_DIR}/share/man
-	rmdir ${D}${CROSS_DIR}/share || :
-	rmdir ${D}${CROSS_DIR}/${libdir}/gcc-lib || :
-	rmdir ${D}${CROSS_DIR}/${libdir}64/gcc-lib || :
-	rmdir ${D}${CROSS_DIR}/${libdir} || :
-	rmdir ${D}${CROSS_DIR}/${libdir}64 || :
-	rmdir ${D}${CROSS_DIR}/${prefix} || :
+	rm -rf ${D}${STAGING_DIR_NATIVE}${prefix_native}/lib/ldscripts
+	rm -rf ${D}${STAGING_DIR_NATIVE}${prefix_native}/share/info
+	rm -rf ${D}${STAGING_DIR_NATIVE}${prefix_native}/share/locale
+	rm -rf ${D}${STAGING_DIR_NATIVE}${prefix_native}/share/man
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/share || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${libdir}/gcc-lib || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${libdir}64/gcc-lib || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${libdir} || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${libdir}64 || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${prefix} || :
 }
recipes/eglibc/eglibc-package.bbclass +2 -2
index 3dc97b4..4e286af 100644
@@ -169,8 +169,8 @@ do_prep_locale_tree() {
 		gunzip $i
 	done
 	ls -d ${PKGD}${base_libdir}/* | xargs -iBLAH cp -pPR BLAH $treedir/lib
-	if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.* ]; then
-		cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.* $treedir/lib
+	if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.* ]; then
+		cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.* $treedir/lib
 	fi
 	install -m 0755 ${PKGD}${bindir}/localedef $treedir/bin
 }
recipes/gcc/gcc-configure-sdk.inc +11 -11
index 205b106..d5a5942 100644
@@ -5,23 +5,23 @@ USE_NLS = '${@base_conditional( "TARGET_OS", "linux-uclibc", "no", "", d )}'
 USE_NLS = '${@base_conditional( "TARGET_OS", "linux-uclibceabi", "no", "", d )}'
 
 EXTRA_OECONF_PATHS = "--with-sysroot=${prefix}/${TARGET_SYS} \
-                      --with-build-time-tools=${CROSS_DIR}/${TARGET_SYS}/bin \
+                      --with-build-time-tools=${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin \
                       --with-build-sysroot=${STAGING_DIR_TARGET}"
 
 #
 # gcc-cross looks and finds these in ${exec_prefix} but we're not so lucky
 # for the sdk. Hardcoding the paths ensures the build doesn't go canadian or worse.
 #
-export AR_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/ar"
-export AS_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/as"
-export DLLTOOL_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/dlltool"
-export LD_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/ld"
-export LIPO_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/lipo"
-export NM_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/nm"
-export OBJDUMP_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/objdump"
-export RANLIB_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/ranlib"
-export STRIP_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/strip"
-export WINDRES_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/windres"
+export AR_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/ar"
+export AS_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/as"
+export DLLTOOL_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/dlltool"
+export LD_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/ld"
+export LIPO_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/lipo"
+export NM_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/nm"
+export OBJDUMP_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/objdump"
+export RANLIB_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/ranlib"
+export STRIP_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/strip"
+export WINDRES_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/windres"
 
 #
 # We need to override this and make sure the compiler can find staging
recipes/gcc/gcc-cross-initial_csl-arm-2007q3.bb +2 -2
index 908b612..dd60164 100644
@@ -5,6 +5,6 @@ S = "${WORKDIR}/gcc-4.2"
 
 # Hack till we fix *libc properly
 do_install_append() {
-	install -d ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include/
-	ln -sf ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include-fixed/* ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include/
+	install -d ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include/
+	ln -sf ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include-fixed/* ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include/
 }
recipes/gcc/gcc-cross-intermediate_csl-arm-2007q3.bb +2 -2
index 89e6a85..b9b34b6 100644
@@ -5,6 +5,6 @@ S = "${WORKDIR}/gcc-4.2"
 
 # Hack till we fix *libc properly
 do_install_append() {
-	install -d ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include
-	ln -sf ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include-fixed/* ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include/
+	install -d ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include
+	ln -sf ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include-fixed/* ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include/
 }
recipes/gcc/gcc-cross-kernel.inc +1 -1
index c0a8de7..e6f1fb8 100644
@@ -19,5 +19,5 @@ do_compile () {
 do_stage () {
 	cd gcc
 	oe_runmake installdirs install-common install-headers install-libgcc
-	install -m 0755 xgcc ${CROSS_DIR}/bin/${TARGET_PREFIX}gcc-${PV}
+	install -m 0755 xgcc ${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}gcc-${PV}
 }
recipes/gcc/gcc-cross-sdk_3.4.4.bb +2 -2
index 16ca9e4..a885c07 100644
@@ -7,7 +7,7 @@ SRC_URI += 'file://sdk-libstdc++-includes.patch'
 
 do_compile_prepend () {
 	mkdir -p gcc
-	ln -s ${CROSS_DIR}/bin/${TARGET_PREFIX}as gcc/as 
-	ln -s ${CROSS_DIR}/bin/${TARGET_PREFIX}ld gcc/ld
+	ln -s ${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}as gcc/as 
+	ln -s ${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}ld gcc/ld
 }
 
recipes/gcc/gcc-cross_csl-arm-2007q3.bb +3 -3
index 945e8ac..70c869e 100644
@@ -14,9 +14,9 @@ LDFLAGS = ""
 
 # staging-linkage and cross-linkage recipes don't work anymore, so do it by hand for this backwards CSL toolchain
 do_compile_prepend() {
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${CROSS_DIR}/${TARGET_SYS}/lib/ 
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/ 
 	sed -i -e 's:gcc_no_link=yes:gcc_no_link=no:' ${S}/libstdc++-v3/configure
 
 }
recipes/gcc/gcc-cross_csl-arm-2008q1.bb +3 -3
index a3edb28..7ed0f51 100644
@@ -14,9 +14,9 @@ LDFLAGS = ""
 
 # staging-linkage and cross-linkage recipes don't work anymore, so do it by hand for this backwards CSL toolchain
 do_compile_prepend() {
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${CROSS_DIR}/${TARGET_SYS}/lib/ 
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/ 
 	sed -i -e 's:gcc_no_link=yes:gcc_no_link=no:' ${S}/libstdc++-v3/configure
 
 }
recipes/gcc/gcc-cross_csl-arm-2008q3.bb +3 -3
index 88b222e..9ada568 100644
@@ -14,9 +14,9 @@ LDFLAGS = ""
 
 # staging-linkage and cross-linkage recipes don't work anymore, so do it by hand for this backwards CSL toolchain
 do_compile_prepend() {
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${CROSS_DIR}/${TARGET_SYS}/lib/ 
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/ 
 	sed -i -e 's:gcc_no_link=yes:gcc_no_link=no:' ${S}/libstdc++-v3/configure
 
 }
recipes/gcc/gcc-package-cross.inc +4 -4
index 95936ed..6978340 100644
@@ -38,12 +38,12 @@ do_install () {
      
 	# Link gfortran to g77 to satisfy not-so-smart configure or hard coded g77
 	# gfortran is fully backwards compatible. This is a safe and practical solution.
-	if [ -f ${D}${CROSS_DIR}/bin/${TARGET_PREFIX}gfortran ]; then
+	if [ -f ${D}${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}gfortran ]; then
 		currdir="$PWD"
-		cd ${D}${CROSS_DIR}/bin/
+		cd ${D}${STAGING_DIR_NATIVE}${prefix_native}/bin/
 		ln -sf ${TARGET_PREFIX}gfortran ${TARGET_PREFIX}g77 || true
-		if [ -d ${CROSS_DIR}/${TARGET_SYS}/bin/ ] ; then 
-			cd ${CROSS_DIR}/${TARGET_SYS}/bin/
+		if [ -d ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/ ] ; then 
+			cd ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/
 			ln -sf gfortran g77 || true
 		fi
 		cd $currdir
Signature · 1 line
1.7.1
Acked-by on v1 2/4
#4 lore raw

Re: [PATCH 2/4] toolchain: Remove references to CROSS_DIR

Quoted 3 lines · Khem Raj

* Toolchain is installed into native sysroot now.

Quoted 220 lines
---
 recipes/binutils/binutils-cross.inc                |   20 +++++++++---------
 recipes/eglibc/eglibc-package.bbclass              |    4 +-
 recipes/gcc/gcc-configure-sdk.inc                  |   22 ++++++++++----------
 recipes/gcc/gcc-cross-initial_csl-arm-2007q3.bb    |    4 +-
 .../gcc/gcc-cross-intermediate_csl-arm-2007q3.bb   |    4 +-
 recipes/gcc/gcc-cross-kernel.inc                   |    2 +-
 recipes/gcc/gcc-cross-sdk_3.4.4.bb                 |    4 +-
 recipes/gcc/gcc-cross_csl-arm-2007q3.bb            |    6 ++--
 recipes/gcc/gcc-cross_csl-arm-2008q1.bb            |    6 ++--
 recipes/gcc/gcc-cross_csl-arm-2008q3.bb            |    6 ++--
 recipes/gcc/gcc-package-cross.inc                  |    8 +++---
 11 files changed, 43 insertions(+), 43 deletions(-)
recipes/binutils/binutils-cross.inc +10 -10
index 432e1a7..f3ba5c3 100644
@@ -16,14 +16,14 @@ do_install () {
 	${D}${libdir}/libiberty_pic.a
 
 	# We don't really need these, so we'll remove them...
-	rm -rf ${D}${CROSS_DIR}/lib/ldscripts
-	rm -rf ${D}${CROSS_DIR}/share/info
-	rm -rf ${D}${CROSS_DIR}/share/locale
-	rm -rf ${D}${CROSS_DIR}/share/man
-	rmdir ${D}${CROSS_DIR}/share || :
-	rmdir ${D}${CROSS_DIR}/${libdir}/gcc-lib || :
-	rmdir ${D}${CROSS_DIR}/${libdir}64/gcc-lib || :
-	rmdir ${D}${CROSS_DIR}/${libdir} || :
-	rmdir ${D}${CROSS_DIR}/${libdir}64 || :
-	rmdir ${D}${CROSS_DIR}/${prefix} || :
+	rm -rf ${D}${STAGING_DIR_NATIVE}${prefix_native}/lib/ldscripts
+	rm -rf ${D}${STAGING_DIR_NATIVE}${prefix_native}/share/info
+	rm -rf ${D}${STAGING_DIR_NATIVE}${prefix_native}/share/locale
+	rm -rf ${D}${STAGING_DIR_NATIVE}${prefix_native}/share/man
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/share || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${libdir}/gcc-lib || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${libdir}64/gcc-lib || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${libdir} || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${libdir}64 || :
+	rmdir ${D}${STAGING_DIR_NATIVE}${prefix_native}/${prefix} || :
 }
recipes/eglibc/eglibc-package.bbclass +2 -2
index 3dc97b4..4e286af 100644
@@ -169,8 +169,8 @@ do_prep_locale_tree() {
 		gunzip $i
 	done
 	ls -d ${PKGD}${base_libdir}/* | xargs -iBLAH cp -pPR BLAH $treedir/lib
-	if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.* ]; then
-		cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.* $treedir/lib
+	if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.* ]; then
+		cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.* $treedir/lib
 	fi
 	install -m 0755 ${PKGD}${bindir}/localedef $treedir/bin
 }
recipes/gcc/gcc-configure-sdk.inc +11 -11
index 205b106..d5a5942 100644
@@ -5,23 +5,23 @@ USE_NLS = '${@base_conditional( "TARGET_OS", "linux-uclibc", "no", "", d )}'
 USE_NLS = '${@base_conditional( "TARGET_OS", "linux-uclibceabi", "no", "", d )}'
 
 EXTRA_OECONF_PATHS = "--with-sysroot=${prefix}/${TARGET_SYS} \
-                      --with-build-time-tools=${CROSS_DIR}/${TARGET_SYS}/bin \
+                      --with-build-time-tools=${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin \
                       --with-build-sysroot=${STAGING_DIR_TARGET}"
 
 #
 # gcc-cross looks and finds these in ${exec_prefix} but we're not so lucky
 # for the sdk. Hardcoding the paths ensures the build doesn't go canadian or worse.
 #
-export AR_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/ar"
-export AS_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/as"
-export DLLTOOL_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/dlltool"
-export LD_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/ld"
-export LIPO_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/lipo"
-export NM_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/nm"
-export OBJDUMP_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/objdump"
-export RANLIB_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/ranlib"
-export STRIP_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/strip"
-export WINDRES_FOR_TARGET = "${CROSS_DIR}/${TARGET_SYS}/bin/windres"
+export AR_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/ar"
+export AS_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/as"
+export DLLTOOL_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/dlltool"
+export LD_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/ld"
+export LIPO_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/lipo"
+export NM_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/nm"
+export OBJDUMP_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/objdump"
+export RANLIB_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/ranlib"
+export STRIP_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/strip"
+export WINDRES_FOR_TARGET = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/windres"
 
 #
 # We need to override this and make sure the compiler can find staging
recipes/gcc/gcc-cross-initial_csl-arm-2007q3.bb +2 -2
index 908b612..dd60164 100644
@@ -5,6 +5,6 @@ S = "${WORKDIR}/gcc-4.2"
 
 # Hack till we fix *libc properly
 do_install_append() {
-	install -d ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include/
-	ln -sf ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include-fixed/* ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include/
+	install -d ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include/
+	ln -sf ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include-fixed/* ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include/
 }
recipes/gcc/gcc-cross-intermediate_csl-arm-2007q3.bb +2 -2
index 89e6a85..b9b34b6 100644
@@ -5,6 +5,6 @@ S = "${WORKDIR}/gcc-4.2"
 
 # Hack till we fix *libc properly
 do_install_append() {
-	install -d ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include
-	ln -sf ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include-fixed/* ${CROSS_DIR}/lib/gcc/${TARGET_SYS}/${BINV}/include/
+	install -d ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include
+	ln -sf ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include-fixed/* ${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/${BINV}/include/
 }
recipes/gcc/gcc-cross-kernel.inc +1 -1
index c0a8de7..e6f1fb8 100644
@@ -19,5 +19,5 @@ do_compile () {
 do_stage () {
 	cd gcc
 	oe_runmake installdirs install-common install-headers install-libgcc
-	install -m 0755 xgcc ${CROSS_DIR}/bin/${TARGET_PREFIX}gcc-${PV}
+	install -m 0755 xgcc ${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}gcc-${PV}
 }
recipes/gcc/gcc-cross-sdk_3.4.4.bb +2 -2
index 16ca9e4..a885c07 100644
@@ -7,7 +7,7 @@ SRC_URI += 'file://sdk-libstdc++-includes.patch'
 
 do_compile_prepend () {
 	mkdir -p gcc
-	ln -s ${CROSS_DIR}/bin/${TARGET_PREFIX}as gcc/as 
-	ln -s ${CROSS_DIR}/bin/${TARGET_PREFIX}ld gcc/ld
+	ln -s ${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}as gcc/as 
+	ln -s ${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}ld gcc/ld
 }
 
recipes/gcc/gcc-cross_csl-arm-2007q3.bb +3 -3
index 945e8ac..70c869e 100644
@@ -14,9 +14,9 @@ LDFLAGS = ""
 
 # staging-linkage and cross-linkage recipes don't work anymore, so do it by hand for this backwards CSL toolchain
 do_compile_prepend() {
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${CROSS_DIR}/${TARGET_SYS}/lib/ 
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/ 
 	sed -i -e 's:gcc_no_link=yes:gcc_no_link=no:' ${S}/libstdc++-v3/configure
 
 }
recipes/gcc/gcc-cross_csl-arm-2008q1.bb +3 -3
index a3edb28..7ed0f51 100644
@@ -14,9 +14,9 @@ LDFLAGS = ""
 
 # staging-linkage and cross-linkage recipes don't work anymore, so do it by hand for this backwards CSL toolchain
 do_compile_prepend() {
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${CROSS_DIR}/${TARGET_SYS}/lib/ 
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/ 
 	sed -i -e 's:gcc_no_link=yes:gcc_no_link=no:' ${S}/libstdc++-v3/configure
 
 }
recipes/gcc/gcc-cross_csl-arm-2008q3.bb +3 -3
index 88b222e..9ada568 100644
@@ -14,9 +14,9 @@ LDFLAGS = ""
 
 # staging-linkage and cross-linkage recipes don't work anymore, so do it by hand for this backwards CSL toolchain
 do_compile_prepend() {
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${CROSS_DIR}/${TARGET_SYS}/lib/
-	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${CROSS_DIR}/${TARGET_SYS}/lib/ 
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/crt*.o ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}${target_libdir}/ld-* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/
+	ln -sf ${STAGING_DIR_TARGET}/lib/libc* ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/ 
 	sed -i -e 's:gcc_no_link=yes:gcc_no_link=no:' ${S}/libstdc++-v3/configure
 
 }
recipes/gcc/gcc-package-cross.inc +4 -4
index 95936ed..6978340 100644
@@ -38,12 +38,12 @@ do_install () {
 
 	# Link gfortran to g77 to satisfy not-so-smart configure or hard coded g77
 	# gfortran is fully backwards compatible. This is a safe and practical solution.
-	if [ -f ${D}${CROSS_DIR}/bin/${TARGET_PREFIX}gfortran ]; then
+	if [ -f ${D}${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}gfortran ]; then
 		currdir="$PWD"
-		cd ${D}${CROSS_DIR}/bin/
+		cd ${D}${STAGING_DIR_NATIVE}${prefix_native}/bin/
 		ln -sf ${TARGET_PREFIX}gfortran ${TARGET_PREFIX}g77 || true
-		if [ -d ${CROSS_DIR}/${TARGET_SYS}/bin/ ] ; then 
-			cd ${CROSS_DIR}/${TARGET_SYS}/bin/
+		if [ -d ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/ ] ; then 
+			cd ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin/
 			ln -sf gfortran g77 || true
 		fi
 		cd $currdir
Signature · 2 lines
Tom Rini
Mentor Graphics Corporation
author
#5 lore raw

PATCH 3/4 recipes: Fix references to CROSS_DIR

In reply to Khem Raj
---
 recipes/apex/apex-env_1.5.14.bb                |    6 +++---
 recipes/apex/apex-env_1.5.8.bb                 |    6 +++---
 recipes/apex/apex-nslu2-16mb_1.5.14.bb         |    6 +++---
 recipes/apex/apex-nslu2_1.5.14.bb              |    6 +++---
 recipes/arm-kernel-shim/arm-kernel-shim_1.5.bb |   18 +++++++++---------
 recipes/avr-libc/avr-libc_1.0.3.bb             |    2 +-
 recipes/bl/bl_cvs.bb                           |    2 +-
 recipes/chromium/chromium_svn.bb               |    2 +-
 recipes/dejagnu/dejagnu-qemu_1.0.bb            |    2 +-
 recipes/dietlibc/dietlibc.inc                  |    4 ++--
 recipes/emacs/emacs.inc                        |   10 +++++-----
 recipes/emacs/emacs_cvs.bb                     |    6 +++---
 recipes/gstreamer/gst-ffmpeg_0.10.10.bb        |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.2.bb         |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.4.bb         |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.6.bb         |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.7.bb         |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.8.bb         |    2 +-
 recipes/iphone/gcc-iphone-cross_git.bb         |    4 ++--
 recipes/klibc/klibc.inc                        |    2 +-
 recipes/led/led_cvs.bb                         |    2 +-
 recipes/mamona/binutils-noemu_2.17.50.0.5.bb   |    2 +-
 recipes/meta/cross-linkage_1.0.bb              |   18 +++++++++---------
 recipes/musicbrainz/libmusicbrainz.inc         |    2 +-
 recipes/openmoko2/openmoko-browser2_svn.bb     |    2 +-
 recipes/perl/perl_5.10.1.bb                    |    2 +-
 recipes/perl/perl_5.8.8.bb                     |    2 +-
 recipes/phoneme/phoneme-advanced.inc           |    2 +-
 recipes/qi/qi.inc                              |    2 +-
 recipes/uclibc/bfin-uclibc_svn.bb              |    2 +-
 recipes/wvstreams/wvstreams_4.2.2.bb           |    2 +-
 recipes/wvstreams/wvstreams_4.4.1.bb           |    2 +-
 recipes/wvstreams/wvstreams_4.6.bb             |    2 +-
 33 files changed, 65 insertions(+), 65 deletions(-)
recipes/apex/apex-env_1.5.14.bb +3 -3
index ddd28f3..cb44bd5 100644
@@ -10,11 +10,11 @@ SRC_URI = "ftp://ftp.buici.com/pub/apex/apex-${PV}.tar.gz \
 	"
 S = ${WORKDIR}/apex-${PV}/usr
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@"
-	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@"
+	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
 }
 
 do_install() {
recipes/apex/apex-env_1.5.8.bb +3 -3
index b619026..d2cf0b7 100644
@@ -10,11 +10,11 @@ SRC_URI = "ftp://ftp.buici.com/pub/apex/apex-${PV}.tar.gz \
 	"
 S = ${WORKDIR}/apex-${PV}/usr
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@"
-	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@"
+	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
 }
 
 do_install() {
recipes/apex/apex-nslu2-16mb_1.5.14.bb +3 -3
index 8e764dd..1e654df 100644
@@ -17,11 +17,11 @@ CMDLINE_ROOT  ?= "root=/dev/mtdblock4 rootfstype=jffs2 rw"
 
 CMDLINE_DEBUG ?= ""
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@"
-	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@"
+	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
 }
 
 # Set the correct CONFIG_USER_xxx_ENDIAN and CONFIG_CMDLINE at the head
recipes/apex/apex-nslu2_1.5.14.bb +3 -3
index a1d91b7..efab695 100644
@@ -17,11 +17,11 @@ CMDLINE_ROOT  ?= "root=/dev/mtdblock4 rootfstype=jffs2 rw"
 
 CMDLINE_DEBUG ?= ""
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@"
-	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@"
+	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
 }
 
 # Set the correct CONFIG_USER_xxx_ENDIAN and CONFIG_CMDLINE at the head
recipes/arm-kernel-shim/arm-kernel-shim_1.5.bb +9 -9
index f02cc95..76e2606 100644
@@ -27,7 +27,7 @@ CMDLINE_ROOT_NAS100D = "root=/dev/mtdblock2 rootfstype=jffs2 rootflags=noatime r
 CMDLINE_ROOT_NSLU2   = "root=/dev/mtdblock4 rootfstype=jffs2 rootflags=noatime rw init=/linuxrc"
 # CMDLINE is passed correctly on the Freecom FSG-3 from the bootloader.
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
 	mv ${S}/config.h ${S}/config.h.orig
@@ -41,8 +41,8 @@ oe_runmake() {
 	fi
 	echo "#define COMMANDLINE \"${CMDLINE_CONSOLE} ${CMDLINE_ROOT_NSLU2} ${CMDLINE_DEBUG}\"" >> ${S}/config.h
 	rm -f ${S}/main.o
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2
-	make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2 || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2
+	make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2 || die "oe_runmake failed"
 	# NAS100d
 	if [ ${SITEINFO_ENDIANESS} == "be" ] ; then
 		sed -e 's|//#define FORCE_BIGENDIAN|#define FORCE_BIGENDIAN|' \
@@ -53,8 +53,8 @@ oe_runmake() {
 	fi
 	echo "#define COMMANDLINE \"${CMDLINE_CONSOLE} ${CMDLINE_ROOT_NAS100D} ${CMDLINE_DEBUG}\"" >> ${S}/config.h
 	rm -f ${S}/main.o
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d
-	make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d
+	make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d || die "oe_runmake failed"
 	# DSMG-600
 	if [ ${SITEINFO_ENDIANESS} == "be" ] ; then
 		sed -e 's|//#define FORCE_BIGENDIAN|#define FORCE_BIGENDIAN|' \
@@ -65,8 +65,8 @@ oe_runmake() {
 	fi
 	echo "#define COMMANDLINE \"${CMDLINE_CONSOLE} ${CMDLINE_ROOT_DSMG600} ${CMDLINE_DEBUG}\"" >> ${S}/config.h
 	rm -f ${S}/main.o
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-dsmg600
-	make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-dsmg600 || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-dsmg600
+	make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-dsmg600 || die "oe_runmake failed"
 	# FSG-3
 	if [ ${SITEINFO_ENDIANESS} == "be" ] ; then
 		sed -e 's|//#define FORCE_BIGENDIAN|#define FORCE_BIGENDIAN|' \
@@ -76,8 +76,8 @@ oe_runmake() {
 			${WORKDIR}/config-fsg3.h > ${S}/config.h
 	fi
 	rm -f ${S}/main.o
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3
-	make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3 || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3
+	make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3 || die "oe_runmake failed"
 	mv ${S}/config.h.orig ${S}/config.h
 }
 
recipes/avr-libc/avr-libc_1.0.3.bb +1 -1
index 052425b..efd2967 100644
@@ -18,7 +18,7 @@ B = "${WORKDIR}/build.${BUILD_SYS}.${TARGET_SYS}"
 inherit autotools
 
 export tooldir = "${prefix}"
-prefix = "${CROSS_DIR}"
+prefix = "${STAGING_DIR_NATIVE}${prefix_native}"
 exec_prefix = "${prefix}"
 
 do_stage () {
recipes/bl/bl_cvs.bb +1 -1
index cdbf2ba..779ff1e 100644
@@ -21,7 +21,7 @@ do_configure (){
 }
 
 do_compile (){
-	oe_runmake bl CC="${CROSS_DIR}/bin/${TARGET_SYS}-gcc -I{STAGING_INCDIR} -L${STAGING_LIBDIR}" AS=${CROSS_DIR}/bin/${TARGET_SYS}-as LD=${CROSS_DIR}/bin/${TARGET_SYS}-ld
+	oe_runmake bl CC="${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-gcc -I{STAGING_INCDIR} -L${STAGING_LIBDIR}" AS=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-as LD=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-ld
 }
 
 do_install () {
recipes/chromium/chromium_svn.bb +1 -1
index a71f947..6aeab44 100644
@@ -100,7 +100,7 @@ TARGET_CC_ARCH += "${LDFLAGS}"
 
 do_compile() {
 	cd ${S}
-	export CROSSTOOL=${CROSS_DIR}/bin/${TARGET_PREFIX}
+	export CROSSTOOL=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}
 	export AR=${CROSSTOOL}ar
 	export AS=${CROSSTOOL}as
 	export RANLIB=${CROSSTOOL}ranlib
recipes/dejagnu/dejagnu-qemu_1.0.bb +1 -1
index 2eef27e..89cea80 100644
@@ -13,7 +13,7 @@ do_stage() {
 	install -m 0644 ${WORKDIR}/arm-qemu.exp ${STAGING_DATADIR}/dejagnu/baseboards/
 	cat <<EOF >${STAGING_BINDIR_NATIVE}/${QEMU}-test-wrapper
 #!/bin/sh
-exec ${QEMU} ${CROSS_DIR}/${TARGET_SYS}/${LD_SO} --library-path ${CROSS_DIR}/${TARGET_SYS}/lib:${STAGING_DIR_TARGET}${layout_libdir} \$1
+exec ${QEMU} ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/${LD_SO} --library-path ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib:${STAGING_DIR_TARGET}${layout_libdir} \$1
 EOF
 	chmod 755 ${STAGING_BINDIR_NATIVE}/arm-qemu-test-wrapper
 }
recipes/dietlibc/dietlibc.inc +2 -2
index 624a9ae..a1537e1 100644
@@ -29,12 +29,12 @@ do_stage () {
 	DIETLIBC_BUILD_ARCH=`echo ${BUILD_ARCH} | sed -e s'/.86/386/'`
 	DIETLIBC_TARGET_ARCH=`echo ${TARGET_ARCH} | sed -e s'/.86/386/'`
 	rm -rf ${STAGING_DIR_TARGET}/lib/dietlibc || true
-	rm ${CROSS_DIR}/bin/diet || true
+	rm ${STAGING_DIR_NATIVE}${prefix_native}/bin/diet || true
 	install -d ${STAGING_DIR_TARGET}/lib/dietlibc/lib-${DIETLIBC_TARGET_ARCH}
 	install -d ${STAGING_DIR_TARGET}/lib/dietlibc/include
         for i in `find include -name \*.h`; do install -m 644 -D $i ${STAGING_DIR_TARGET}/lib/dietlibc/$i; done
 
-        install -m755 bin-${DIETLIBC_BUILD_ARCH}/diet-i ${CROSS_DIR}/bin/diet
+        install -m755 bin-${DIETLIBC_BUILD_ARCH}/diet-i ${STAGING_DIR_NATIVE}${prefix_native}/bin/diet
 	
 	cd bin-${DIETLIBC_TARGET_ARCH}
 	install -m 644 start.o libm.a libpthread.a librpc.a \
recipes/emacs/emacs.inc +5 -5
index 6645f41..893ee9d 100644
@@ -32,7 +32,7 @@ export LOGNAME = "$(whoami)"
 
 do_compile_prepend() {
 	sed -i ':1;s:\(START.* \|LIB_STANDARD.* \|LIBES.* \)/usr/lib:\1${STAGING_LIBDIR}:;t1' ${S}/src/s/gnu-linux.h `find "${S}" -name Makefile`
-	export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${CROSS_DIR}/${TARGET_SYS}/lib"
+	export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 # Ugly hack, see files/use-qemu.patch for more:
 	ln -sf ../src/emacs lisp/emacs
 	ln -sf ../src/emacs lib-src/emacs
@@ -44,11 +44,11 @@ do_compile_prepend() {
 	fi
 	mkdir $treedir
 	cp -pPR ${STAGING_DIR_TARGET}/* $treedir
-	if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so ]; then
-                cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so $treedir/lib
+	if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so ]; then
+                cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so $treedir/lib
         fi
-        if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.* ]; then
-                cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.* $treedir/lib
+        if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so.* ]; then
+                cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so.* $treedir/lib
         fi
 	# stupid hack, but without it, it tries to use /usr/lib/libc.so from host and fails
 	# temacs: error while loading shared libraries: /usr/lib/libc.so: ELF file version does not match current one
recipes/emacs/emacs_cvs.bb +3 -3
index c3a98a3..a2065be 100644
@@ -27,12 +27,12 @@ FILES_${PN}-el = "${datadir}/emacs/*/*/*.el.gz \
 FILES_${PN} += "${datadir}/emacs"
 
 QEMU = "qemu-${TARGET_ARCH} -L ${STAGING_DIR_TARGET}"
-LDFLAGS += "-L${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS += "-L${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 EXTRA_OECONF = "--without-sound --without-x"
 
 do_bootstrap() {
-    cp "${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.1" "${S}"
+    cp "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so.1" "${S}"
     export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${S}"
     export QEMU="${QEMU}"
 
@@ -46,7 +46,7 @@ do_bootstrap() {
 addtask bootstrap before do_compile after do_configure
 
 do_compile_prepend() {
-    cp "${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.1" "${S}"
+    cp "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so.1" "${S}"
     export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${S}"
     export QEMU="${QEMU}"
 }
recipes/gstreamer/gst-ffmpeg_0.10.10.bb +1 -1
index c29e3b6..9b0269c 100644
@@ -22,7 +22,7 @@ EXTRA_OECONF = " --with-system-ffmpeg "
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.2.bb +1 -1
index c835011..f2c2654 100644
@@ -25,7 +25,7 @@ EXTRA_OECONF = "--disable-sdltest --disable-ffplay --disable-freetypetest \
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.4.bb +1 -1
index 19d1bb1..28a753d 100644
@@ -24,7 +24,7 @@ EXTRA_OECONF = "--disable-sdltest --disable-ffplay --disable-freetypetest \
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.6.bb +1 -1
index 0a9b373..9b8ec8d 100644
@@ -25,7 +25,7 @@ EXTRA_OECONF = "--disable-sdltest --disable-ffplay --disable-freetypetest \
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.7.bb +1 -1
index c9e33de..8a1d56e 100644
@@ -25,7 +25,7 @@ EXTRA_OECONF = "--disable-sdltest --disable-ffplay --disable-freetypetest \
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.8.bb +1 -1
index 2e5b84e..2bdc45b 100644
@@ -21,7 +21,7 @@ EXTRA_OECONF = " --with-system-ffmpeg "
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/iphone/gcc-iphone-cross_git.bb +2 -2
index ea351cf..3c6a788 100644
@@ -20,8 +20,8 @@ EXTRA_OECONF = "\
 	--enable-sjlj-exceptions \
 	--enable-wchar_t=no  \
 	--with-gxx-include-dir=${STAGING_DIR_TARGET}/${layout_includedir}/c++ \
-	--with-as=${CROSS_DIR}/bin/${TARGET_PREFIX}as \
-	--with-ld=${CROSS_DIR}/bin/${TARGET_PREFIX}ld \
+	--with-as=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}as \
+	--with-ld=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}ld \
 	--with-sysroot=${STAGING_DIR_TARGET} \
 	--with-build-sysroot=${STAGING_DIR_TARGET} \
 	--with-local-prefix=${STAGING_DIR_TARGET}${layout_prefix} \
recipes/klibc/klibc.inc +1 -1
index 9ae6c5b..d0f8e1c 100644
@@ -13,7 +13,7 @@ do_install() {
 export INST=${STAGING_DIR_TARGET}
 do_stage() {
         oe_runmake  install
-        cp '${STAGING_DIR_TARGET}/bin/klcc'  '${CROSS_DIR}/bin/${TARGET_PREFIX}klcc'
+        cp '${STAGING_DIR_TARGET}/bin/klcc'  '${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}klcc'
 }
 
 PACKAGES = "${PN} ${PN}-dev "
recipes/led/led_cvs.bb +1 -1
index 6f303d1..90eb116 100644
@@ -19,7 +19,7 @@ do_configure (){
 }
 
 do_compile (){
-	oe_runmake led CC="${CROSS_DIR}/bin/${TARGET_SYS}-gcc -I${STAGING_INCDIR} -I${STAGING_KERNEL_DIR}/include  -L${STAGING_LIBDIR}" AS=${CROSS_DIR}/bin/${TARGET_SYS}-as LD=${CROSS_DIR}/bin/${TARGET_SYS}-ld
+	oe_runmake led CC="${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-gcc -I${STAGING_INCDIR} -I${STAGING_KERNEL_DIR}/include  -L${STAGING_LIBDIR}" AS=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-as LD=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-ld
 }
 
 do_install () {
recipes/mamona/binutils-noemu_2.17.50.0.5.bb +1 -1
index f2362ff..c3e2b31 100644
@@ -16,7 +16,7 @@ SRC_URI = \
      file://binutils-uclibc-300-012_check_ldrunpath_length.patch \
      "
 
-EXTRA_OECONF = "--with-sysroot=${CROSS_DIR}/${TARGET_SYS} \
+EXTRA_OECONF = "--with-sysroot=${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS} \
 		--program-prefix=${TARGET_PREFIX} --disable-shared"
 
 HOST_SYS = "${BUILD_SYS}"
recipes/meta/cross-linkage_1.0.bb +9 -9
index 9be09aa..a5e456b 100644
@@ -21,15 +21,15 @@ do_install() {
 }
 
 do_stage () {
-	install -d ${CROSS_DIR}/${TARGET_SYS}/
-	if [ -e ${CROSS_DIR}/${TARGET_SYS}/include ]; then
-		cp -pPRr ${CROSS_DIR}/${TARGET_SYS}/include/* ${STAGING_INCDIR}
-		mv ${CROSS_DIR}/${TARGET_SYS}/include/ ${CROSS_DIR}/${TARGET_SYS}/include-oldbackup
+	install -d ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/
+	if [ -e ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include ]; then
+		cp -pPRr ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include/* ${STAGING_INCDIR}
+		mv ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include/ ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include-oldbackup
 	fi
-	ln -s  ${STAGING_INCDIR}/ ${CROSS_DIR}/${TARGET_SYS}/include
-	if [ -e ${CROSS_DIR}/${TARGET_SYS}/lib ]; then
-		cp -pPRr ${CROSS_DIR}/${TARGET_SYS}/lib/* ${STAGING_LIBDIR}
-		mv ${CROSS_DIR}/${TARGET_SYS}/lib/ ${CROSS_DIR}/${TARGET_SYS}/lib-oldbackup
+	ln -s  ${STAGING_INCDIR}/ ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include
+	if [ -e ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib ]; then
+		cp -pPRr ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/* ${STAGING_LIBDIR}
+		mv ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/ ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib-oldbackup
 	fi
-	ln -s  ${STAGING_LIBDIR} ${CROSS_DIR}/${TARGET_SYS}/lib 
+	ln -s  ${STAGING_LIBDIR} ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib 
 }
recipes/musicbrainz/libmusicbrainz.inc +1 -1
index 010dd23..1838d4e 100644
@@ -10,7 +10,7 @@ SRC_URI = "ftp://ftp.musicbrainz.org/pub/musicbrainz/libmusicbrainz-${PV}.tar.gz
 inherit cmake pkgconfig
 
 # Fight a compiler/link bug that leaks too many c++ symbols
-TARGET_LDFLAGS += " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib -ldl"
+TARGET_LDFLAGS += " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib -ldl"
 
 do_stage() {
 	autotools_stage_all
recipes/openmoko2/openmoko-browser2_svn.bb +1 -1
index 3d329b7..a4d8164 100644
@@ -6,7 +6,7 @@ PV = "0.0.1+svnr${SRCPV}"
 PR = "r2"
 
 inherit openmoko2
-LDFLAGS_append = " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS_append = " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 SRC_URI += "file://webkit-update.patch;minrev=3646;maxrev=4171"
 
recipes/perl/perl_5.10.1.bb +1 -1
index c22ecd7..86b08dc 100644
@@ -129,7 +129,7 @@ do_install() {
                    -e "s,${STAGING_LIBDIR},${libdir},g" \
                    -e "s,${STAGING_BINDIR},${bindir},g" \
                    -e "s,${STAGING_INCDIR},${includedir},g" \
-                   -e "s,${CROSS_DIR}${base_bindir}/,,g" \
+                   -e "s,${STAGING_DIR_NATIVE}${prefix_native}${base_bindir}/,,g" \
                 ${D}${bindir}/h2xs \
                 ${D}${bindir}/h2ph \
                 ${D}${datadir}/perl/${PV}/pod/*.pod \
recipes/perl/perl_5.8.8.bb +1 -1
index f09360f..c73fe4e 100644
@@ -135,7 +135,7 @@ do_install() {
                    -e "s,${STAGING_LIBDIR},${libdir},g" \
                    -e "s,${STAGING_BINDIR},${bindir},g" \
                    -e "s,${STAGING_INCDIR},${includedir},g" \
-                   -e "s,${CROSS_DIR}${base_bindir}/,,g" \
+                   -e "s,${STAGING_DIR_NATIVE}${prefix_native}${base_bindir}/,,g" \
                 ${D}${bindir}/h2xs \
                 ${D}${bindir}/h2ph \
                 ${D}${datadir}/perl/${PV}/pod/*.pod \
recipes/phoneme/phoneme-advanced.inc +1 -1
index a74bc04..9df61a6 100644
@@ -66,7 +66,7 @@ do_configure() {
 
   pmo "# Java toolchain binaries"
   pmo JDK_HOME /dev/null
-  pmo CVM_TARGET_TOOLS_PREFIX ${CROSS_DIR}/bin/
+  pmo CVM_TARGET_TOOLS_PREFIX ${STAGING_DIR_NATIVE}${prefix_native}/bin/
   pmo CVM_JAVA java
   pmo CVM_JAVAC javac
   pmo CVM_JAVADOC true
recipes/qi/qi.inc +1 -1
index 0b5451a..f9d4f2e 100644
@@ -21,7 +21,7 @@ BUILD_DATE=\$(shell date --iso-8601=seconds)
 # has been built. If it bails out with something like: "| arm-linux-ld: 4.3.3: No such file or directory"
 # then you need to remove all previously built toolchain directories out of the cross library path.
 GCCV="`${CC} -dumpversion`"
-COMPILER_LIB_PATH_PRE=${CROSS_DIR}/lib/gcc/${TARGET_SYS}/$(GCCV)
+COMPILER_LIB_PATH_PRE=${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/$(GCCV)
 COMPILER_LIB_PATH=\$(COMPILER_LIB_PATH_PRE)/\$(shell ls \$(COMPILER_LIB_PATH_PRE))
 
 AS=${AS}
recipes/uclibc/bfin-uclibc_svn.bb +1 -1
index 2757fc2..954d10d 100644
@@ -20,7 +20,7 @@ COMPATIBLE_HOST = "bfin.*-uclinux"
 
 #as stated above, uclibc needs real kernel-headers
 #however: we can't depend on virtual/kernel when nptl hits due to depends deadlocking ....
-KERNEL_SOURCE = "${CROSS_DIR}/${TARGET_SYS}"
+KERNEL_SOURCE = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}"
 
 SRC_URI = "svn://sources.blackfin.uclinux.org/toolchain/trunk;module=uClibc "
 SRC_URI += "file://uClibc.machine file://uClibc.distro"
recipes/wvstreams/wvstreams_4.2.2.bb +1 -1
index 83f97be..4358ec1 100644
@@ -12,7 +12,7 @@ SRC_URI = "http://ftp.de.debian.org/debian/pool/main/w/wvstreams/${PN}_${PV}.ori
 
 inherit autotools pkgconfig
 
-LDFLAGS_append = " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS_append = " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 EXTRA_AUTORECONF += " -I${S}/gnulib/m4"
 EXTRA_OECONF = " --without-tcl --without-qt --without-pam"
recipes/wvstreams/wvstreams_4.4.1.bb +1 -1
index fa865c7..4506b05 100644
@@ -14,7 +14,7 @@ SRC_URI = "http://wvstreams.googlecode.com/files/${PN}-${PV}.tar.gz \
 
 inherit autotools pkgconfig
 
-LDFLAGS_append = " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS_append = " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 EXTRA_AUTORECONF += " -I${S}/gnulib/m4"
 EXTRA_OECONF = " --without-tcl --without-qt --without-pam"
recipes/wvstreams/wvstreams_4.6.bb +1 -1
index a52c284..eb70fd2 100644
@@ -8,7 +8,7 @@ SRC_URI = "http://wvstreams.googlecode.com/files/${PN}-${PV}.tar.gz \
 
 inherit autotools pkgconfig
 
-LDFLAGS_append = " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS_append = " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 EXTRA_OECONF = " --without-tcl --without-qt --without-pam"
 
Signature · 1 line
1.7.1
Acked-by on v1 3/4
#6 lore raw

Re: [PATCH 3/4] recipes: Fix references to CROSS_DIR

Quoted 1 line · Khem Raj
Quoted 588 lines
---
 recipes/apex/apex-env_1.5.14.bb                |    6 +++---
 recipes/apex/apex-env_1.5.8.bb                 |    6 +++---
 recipes/apex/apex-nslu2-16mb_1.5.14.bb         |    6 +++---
 recipes/apex/apex-nslu2_1.5.14.bb              |    6 +++---
 recipes/arm-kernel-shim/arm-kernel-shim_1.5.bb |   18 +++++++++---------
 recipes/avr-libc/avr-libc_1.0.3.bb             |    2 +-
 recipes/bl/bl_cvs.bb                           |    2 +-
 recipes/chromium/chromium_svn.bb               |    2 +-
 recipes/dejagnu/dejagnu-qemu_1.0.bb            |    2 +-
 recipes/dietlibc/dietlibc.inc                  |    4 ++--
 recipes/emacs/emacs.inc                        |   10 +++++-----
 recipes/emacs/emacs_cvs.bb                     |    6 +++---
 recipes/gstreamer/gst-ffmpeg_0.10.10.bb        |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.2.bb         |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.4.bb         |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.6.bb         |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.7.bb         |    2 +-
 recipes/gstreamer/gst-ffmpeg_0.10.8.bb         |    2 +-
 recipes/iphone/gcc-iphone-cross_git.bb         |    4 ++--
 recipes/klibc/klibc.inc                        |    2 +-
 recipes/led/led_cvs.bb                         |    2 +-
 recipes/mamona/binutils-noemu_2.17.50.0.5.bb   |    2 +-
 recipes/meta/cross-linkage_1.0.bb              |   18 +++++++++---------
 recipes/musicbrainz/libmusicbrainz.inc         |    2 +-
 recipes/openmoko2/openmoko-browser2_svn.bb     |    2 +-
 recipes/perl/perl_5.10.1.bb                    |    2 +-
 recipes/perl/perl_5.8.8.bb                     |    2 +-
 recipes/phoneme/phoneme-advanced.inc           |    2 +-
 recipes/qi/qi.inc                              |    2 +-
 recipes/uclibc/bfin-uclibc_svn.bb              |    2 +-
 recipes/wvstreams/wvstreams_4.2.2.bb           |    2 +-
 recipes/wvstreams/wvstreams_4.4.1.bb           |    2 +-
 recipes/wvstreams/wvstreams_4.6.bb             |    2 +-
 33 files changed, 65 insertions(+), 65 deletions(-)
recipes/apex/apex-env_1.5.14.bb +3 -3
index ddd28f3..cb44bd5 100644
@@ -10,11 +10,11 @@ SRC_URI = "ftp://ftp.buici.com/pub/apex/apex-${PV}.tar.gz \
 	"
 S = ${WORKDIR}/apex-${PV}/usr
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@"
-	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@"
+	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
 }
 
 do_install() {
recipes/apex/apex-env_1.5.8.bb +3 -3
index b619026..d2cf0b7 100644
@@ -10,11 +10,11 @@ SRC_URI = "ftp://ftp.buici.com/pub/apex/apex-${PV}.tar.gz \
 	"
 S = ${WORKDIR}/apex-${PV}/usr
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@"
-	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@"
+	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
 }
 
 do_install() {
recipes/apex/apex-nslu2-16mb_1.5.14.bb +3 -3
index 8e764dd..1e654df 100644
@@ -17,11 +17,11 @@ CMDLINE_ROOT  ?= "root=/dev/mtdblock4 rootfstype=jffs2 rw"
 
 CMDLINE_DEBUG ?= ""
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@"
-	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@"
+	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
 }
 
 # Set the correct CONFIG_USER_xxx_ENDIAN and CONFIG_CMDLINE at the head
recipes/apex/apex-nslu2_1.5.14.bb +3 -3
index a1d91b7..efab695 100644
@@ -17,11 +17,11 @@ CMDLINE_ROOT  ?= "root=/dev/mtdblock4 rootfstype=jffs2 rw"
 
 CMDLINE_DEBUG ?= ""
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@"
-	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@"
+	make ${PARALLEL_MAKE} LDFLAGS= CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} "$@" || die "oe_runmake failed"
 }
 
 # Set the correct CONFIG_USER_xxx_ENDIAN and CONFIG_CMDLINE at the head
recipes/arm-kernel-shim/arm-kernel-shim_1.5.bb +9 -9
index f02cc95..76e2606 100644
@@ -27,7 +27,7 @@ CMDLINE_ROOT_NAS100D = "root=/dev/mtdblock2 rootfstype=jffs2 rootflags=noatime r
 CMDLINE_ROOT_NSLU2   = "root=/dev/mtdblock4 rootfstype=jffs2 rootflags=noatime rw init=/linuxrc"
 # CMDLINE is passed correctly on the Freecom FSG-3 from the bootloader.
 
-EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
+EXTRA_OEMAKE_append = " CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${HOST_PREFIX}"
 
 oe_runmake() {
 	mv ${S}/config.h ${S}/config.h.orig
@@ -41,8 +41,8 @@ oe_runmake() {
 	fi
 	echo "#define COMMANDLINE \"${CMDLINE_CONSOLE} ${CMDLINE_ROOT_NSLU2} ${CMDLINE_DEBUG}\"" >> ${S}/config.h
 	rm -f ${S}/main.o
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2
-	make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2 || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2
+	make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nslu2 || die "oe_runmake failed"
 	# NAS100d
 	if [ ${SITEINFO_ENDIANESS} == "be" ] ; then
 		sed -e 's|//#define FORCE_BIGENDIAN|#define FORCE_BIGENDIAN|' \
@@ -53,8 +53,8 @@ oe_runmake() {
 	fi
 	echo "#define COMMANDLINE \"${CMDLINE_CONSOLE} ${CMDLINE_ROOT_NAS100D} ${CMDLINE_DEBUG}\"" >> ${S}/config.h
 	rm -f ${S}/main.o
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d
-	make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d
+	make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-nas100d || die "oe_runmake failed"
 	# DSMG-600
 	if [ ${SITEINFO_ENDIANESS} == "be" ] ; then
 		sed -e 's|//#define FORCE_BIGENDIAN|#define FORCE_BIGENDIAN|' \
@@ -65,8 +65,8 @@ oe_runmake() {
 	fi
 	echo "#define COMMANDLINE \"${CMDLINE_CONSOLE} ${CMDLINE_ROOT_DSMG600} ${CMDLINE_DEBUG}\"" >> ${S}/config.h
 	rm -f ${S}/main.o
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-dsmg600
-	make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-dsmg600 || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-dsmg600
+	make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-dsmg600 || die "oe_runmake failed"
 	# FSG-3
 	if [ ${SITEINFO_ENDIANESS} == "be" ] ; then
 		sed -e 's|//#define FORCE_BIGENDIAN|#define FORCE_BIGENDIAN|' \
@@ -76,8 +76,8 @@ oe_runmake() {
 			${WORKDIR}/config-fsg3.h > ${S}/config.h
 	fi
 	rm -f ${S}/main.o
-	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3
-	make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3 || die "oe_runmake failed"
+	oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3
+	make ${PARALLEL_MAKE} CROSS_COMPILE=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3 || die "oe_runmake failed"
 	mv ${S}/config.h.orig ${S}/config.h
 }
 
recipes/avr-libc/avr-libc_1.0.3.bb +1 -1
index 052425b..efd2967 100644
@@ -18,7 +18,7 @@ B = "${WORKDIR}/build.${BUILD_SYS}.${TARGET_SYS}"
 inherit autotools
 
 export tooldir = "${prefix}"
-prefix = "${CROSS_DIR}"
+prefix = "${STAGING_DIR_NATIVE}${prefix_native}"
 exec_prefix = "${prefix}"
 
 do_stage () {
recipes/bl/bl_cvs.bb +1 -1
index cdbf2ba..779ff1e 100644
@@ -21,7 +21,7 @@ do_configure (){
 }
 
 do_compile (){
-	oe_runmake bl CC="${CROSS_DIR}/bin/${TARGET_SYS}-gcc -I{STAGING_INCDIR} -L${STAGING_LIBDIR}" AS=${CROSS_DIR}/bin/${TARGET_SYS}-as LD=${CROSS_DIR}/bin/${TARGET_SYS}-ld
+	oe_runmake bl CC="${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-gcc -I{STAGING_INCDIR} -L${STAGING_LIBDIR}" AS=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-as LD=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-ld
 }
 
 do_install () {
recipes/chromium/chromium_svn.bb +1 -1
index a71f947..6aeab44 100644
@@ -100,7 +100,7 @@ TARGET_CC_ARCH += "${LDFLAGS}"
 
 do_compile() {
 	cd ${S}
-	export CROSSTOOL=${CROSS_DIR}/bin/${TARGET_PREFIX}
+	export CROSSTOOL=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}
 	export AR=${CROSSTOOL}ar
 	export AS=${CROSSTOOL}as
 	export RANLIB=${CROSSTOOL}ranlib
recipes/dejagnu/dejagnu-qemu_1.0.bb +1 -1
index 2eef27e..89cea80 100644
@@ -13,7 +13,7 @@ do_stage() {
 	install -m 0644 ${WORKDIR}/arm-qemu.exp ${STAGING_DATADIR}/dejagnu/baseboards/
 	cat <<EOF >${STAGING_BINDIR_NATIVE}/${QEMU}-test-wrapper
 #!/bin/sh
-exec ${QEMU} ${CROSS_DIR}/${TARGET_SYS}/${LD_SO} --library-path ${CROSS_DIR}/${TARGET_SYS}/lib:${STAGING_DIR_TARGET}${layout_libdir} \$1
+exec ${QEMU} ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/${LD_SO} --library-path ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib:${STAGING_DIR_TARGET}${layout_libdir} \$1
 EOF
 	chmod 755 ${STAGING_BINDIR_NATIVE}/arm-qemu-test-wrapper
 }
recipes/dietlibc/dietlibc.inc +2 -2
index 624a9ae..a1537e1 100644
@@ -29,12 +29,12 @@ do_stage () {
 	DIETLIBC_BUILD_ARCH=`echo ${BUILD_ARCH} | sed -e s'/.86/386/'`
 	DIETLIBC_TARGET_ARCH=`echo ${TARGET_ARCH} | sed -e s'/.86/386/'`
 	rm -rf ${STAGING_DIR_TARGET}/lib/dietlibc || true
-	rm ${CROSS_DIR}/bin/diet || true
+	rm ${STAGING_DIR_NATIVE}${prefix_native}/bin/diet || true
 	install -d ${STAGING_DIR_TARGET}/lib/dietlibc/lib-${DIETLIBC_TARGET_ARCH}
 	install -d ${STAGING_DIR_TARGET}/lib/dietlibc/include
         for i in `find include -name \*.h`; do install -m 644 -D $i ${STAGING_DIR_TARGET}/lib/dietlibc/$i; done
 
-        install -m755 bin-${DIETLIBC_BUILD_ARCH}/diet-i ${CROSS_DIR}/bin/diet
+        install -m755 bin-${DIETLIBC_BUILD_ARCH}/diet-i ${STAGING_DIR_NATIVE}${prefix_native}/bin/diet
 
 	cd bin-${DIETLIBC_TARGET_ARCH}
 	install -m 644 start.o libm.a libpthread.a librpc.a \
recipes/emacs/emacs.inc +5 -5
index 6645f41..893ee9d 100644
@@ -32,7 +32,7 @@ export LOGNAME = "$(whoami)"
 
 do_compile_prepend() {
 	sed -i ':1;s:\(START.* \|LIB_STANDARD.* \|LIBES.* \)/usr/lib:\1${STAGING_LIBDIR}:;t1' ${S}/src/s/gnu-linux.h `find "${S}" -name Makefile`
-	export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${CROSS_DIR}/${TARGET_SYS}/lib"
+	export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 # Ugly hack, see files/use-qemu.patch for more:
 	ln -sf ../src/emacs lisp/emacs
 	ln -sf ../src/emacs lib-src/emacs
@@ -44,11 +44,11 @@ do_compile_prepend() {
 	fi
 	mkdir $treedir
 	cp -pPR ${STAGING_DIR_TARGET}/* $treedir
-	if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so ]; then
-                cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so $treedir/lib
+	if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so ]; then
+                cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so $treedir/lib
         fi
-        if [ -f ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.* ]; then
-                cp -pPR ${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.* $treedir/lib
+        if [ -f ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so.* ]; then
+                cp -pPR ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so.* $treedir/lib
         fi
 	# stupid hack, but without it, it tries to use /usr/lib/libc.so from host and fails
 	# temacs: error while loading shared libraries: /usr/lib/libc.so: ELF file version does not match current one
recipes/emacs/emacs_cvs.bb +3 -3
index c3a98a3..a2065be 100644
@@ -27,12 +27,12 @@ FILES_${PN}-el = "${datadir}/emacs/*/*/*.el.gz \
 FILES_${PN} += "${datadir}/emacs"
 
 QEMU = "qemu-${TARGET_ARCH} -L ${STAGING_DIR_TARGET}"
-LDFLAGS += "-L${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS += "-L${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 EXTRA_OECONF = "--without-sound --without-x"
 
 do_bootstrap() {
-    cp "${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.1" "${S}"
+    cp "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so.1" "${S}"
     export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${S}"
     export QEMU="${QEMU}"
 
@@ -46,7 +46,7 @@ do_bootstrap() {
 addtask bootstrap before do_compile after do_configure
 
 do_compile_prepend() {
-    cp "${CROSS_DIR}/${TARGET_SYS}/lib/libgcc_s.so.1" "${S}"
+    cp "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/libgcc_s.so.1" "${S}"
     export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${S}"
     export QEMU="${QEMU}"
 }
recipes/gstreamer/gst-ffmpeg_0.10.10.bb +1 -1
index c29e3b6..9b0269c 100644
@@ -22,7 +22,7 @@ EXTRA_OECONF = " --with-system-ffmpeg "
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.2.bb +1 -1
index c835011..f2c2654 100644
@@ -25,7 +25,7 @@ EXTRA_OECONF = "--disable-sdltest --disable-ffplay --disable-freetypetest \
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.4.bb +1 -1
index 19d1bb1..28a753d 100644
@@ -24,7 +24,7 @@ EXTRA_OECONF = "--disable-sdltest --disable-ffplay --disable-freetypetest \
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.6.bb +1 -1
index 0a9b373..9b8ec8d 100644
@@ -25,7 +25,7 @@ EXTRA_OECONF = "--disable-sdltest --disable-ffplay --disable-freetypetest \
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.7.bb +1 -1
index c9e33de..8a1d56e 100644
@@ -25,7 +25,7 @@ EXTRA_OECONF = "--disable-sdltest --disable-ffplay --disable-freetypetest \
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/gstreamer/gst-ffmpeg_0.10.8.bb +1 -1
index 2e5b84e..2bdc45b 100644
@@ -21,7 +21,7 @@ EXTRA_OECONF = " --with-system-ffmpeg "
 
 # We do this because the install program is called with -s which causes it to
 # call "strip" and it then mangles cross compiled stuff..
-PATH_prepend="${CROSS_DIR}/${TARGET_SYS}/bin:"
+PATH_prepend="${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/bin:"
 
 # Hack to get STAGING_LIBDIR into the linker path when building ffmpeg
 CC = "${CCACHE} ${HOST_PREFIX}gcc ${TARGET_CC_ARCH} -L${STAGING_LIBDIR}"
recipes/iphone/gcc-iphone-cross_git.bb +2 -2
index ea351cf..3c6a788 100644
@@ -20,8 +20,8 @@ EXTRA_OECONF = "\
 	--enable-sjlj-exceptions \
 	--enable-wchar_t=no  \
 	--with-gxx-include-dir=${STAGING_DIR_TARGET}/${layout_includedir}/c++ \
-	--with-as=${CROSS_DIR}/bin/${TARGET_PREFIX}as \
-	--with-ld=${CROSS_DIR}/bin/${TARGET_PREFIX}ld \
+	--with-as=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}as \
+	--with-ld=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}ld \
 	--with-sysroot=${STAGING_DIR_TARGET} \
 	--with-build-sysroot=${STAGING_DIR_TARGET} \
 	--with-local-prefix=${STAGING_DIR_TARGET}${layout_prefix} \
recipes/klibc/klibc.inc +1 -1
index 9ae6c5b..d0f8e1c 100644
@@ -13,7 +13,7 @@ do_install() {
 export INST=${STAGING_DIR_TARGET}
 do_stage() {
         oe_runmake  install
-        cp '${STAGING_DIR_TARGET}/bin/klcc'  '${CROSS_DIR}/bin/${TARGET_PREFIX}klcc'
+        cp '${STAGING_DIR_TARGET}/bin/klcc'  '${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_PREFIX}klcc'
 }
 
 PACKAGES = "${PN} ${PN}-dev "
recipes/led/led_cvs.bb +1 -1
index 6f303d1..90eb116 100644
@@ -19,7 +19,7 @@ do_configure (){
 }
 
 do_compile (){
-	oe_runmake led CC="${CROSS_DIR}/bin/${TARGET_SYS}-gcc -I${STAGING_INCDIR} -I${STAGING_KERNEL_DIR}/include  -L${STAGING_LIBDIR}" AS=${CROSS_DIR}/bin/${TARGET_SYS}-as LD=${CROSS_DIR}/bin/${TARGET_SYS}-ld
+	oe_runmake led CC="${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-gcc -I${STAGING_INCDIR} -I${STAGING_KERNEL_DIR}/include  -L${STAGING_LIBDIR}" AS=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-as LD=${STAGING_DIR_NATIVE}${prefix_native}/bin/${TARGET_SYS}-ld
 }
 
 do_install () {
recipes/mamona/binutils-noemu_2.17.50.0.5.bb +1 -1
index f2362ff..c3e2b31 100644
@@ -16,7 +16,7 @@ SRC_URI = \
      file://binutils-uclibc-300-012_check_ldrunpath_length.patch \
      "
 
-EXTRA_OECONF = "--with-sysroot=${CROSS_DIR}/${TARGET_SYS} \
+EXTRA_OECONF = "--with-sysroot=${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS} \
 		--program-prefix=${TARGET_PREFIX} --disable-shared"
 
 HOST_SYS = "${BUILD_SYS}"
recipes/meta/cross-linkage_1.0.bb +9 -9
index 9be09aa..a5e456b 100644
@@ -21,15 +21,15 @@ do_install() {
 }
 
 do_stage () {
-	install -d ${CROSS_DIR}/${TARGET_SYS}/
-	if [ -e ${CROSS_DIR}/${TARGET_SYS}/include ]; then
-		cp -pPRr ${CROSS_DIR}/${TARGET_SYS}/include/* ${STAGING_INCDIR}
-		mv ${CROSS_DIR}/${TARGET_SYS}/include/ ${CROSS_DIR}/${TARGET_SYS}/include-oldbackup
+	install -d ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/
+	if [ -e ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include ]; then
+		cp -pPRr ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include/* ${STAGING_INCDIR}
+		mv ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include/ ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include-oldbackup
 	fi
-	ln -s  ${STAGING_INCDIR}/ ${CROSS_DIR}/${TARGET_SYS}/include
-	if [ -e ${CROSS_DIR}/${TARGET_SYS}/lib ]; then
-		cp -pPRr ${CROSS_DIR}/${TARGET_SYS}/lib/* ${STAGING_LIBDIR}
-		mv ${CROSS_DIR}/${TARGET_SYS}/lib/ ${CROSS_DIR}/${TARGET_SYS}/lib-oldbackup
+	ln -s  ${STAGING_INCDIR}/ ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/include
+	if [ -e ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib ]; then
+		cp -pPRr ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/* ${STAGING_LIBDIR}
+		mv ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib/ ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib-oldbackup
 	fi
-	ln -s  ${STAGING_LIBDIR} ${CROSS_DIR}/${TARGET_SYS}/lib 
+	ln -s  ${STAGING_LIBDIR} ${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib 
 }
recipes/musicbrainz/libmusicbrainz.inc +1 -1
index 010dd23..1838d4e 100644
@@ -10,7 +10,7 @@ SRC_URI = "ftp://ftp.musicbrainz.org/pub/musicbrainz/libmusicbrainz-${PV}.tar.gz
 inherit cmake pkgconfig
 
 # Fight a compiler/link bug that leaks too many c++ symbols
-TARGET_LDFLAGS += " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib -ldl"
+TARGET_LDFLAGS += " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib -ldl"
 
 do_stage() {
 	autotools_stage_all
recipes/openmoko2/openmoko-browser2_svn.bb +1 -1
index 3d329b7..a4d8164 100644
@@ -6,7 +6,7 @@ PV = "0.0.1+svnr${SRCPV}"
 PR = "r2"
 
 inherit openmoko2
-LDFLAGS_append = " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS_append = " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 SRC_URI += "file://webkit-update.patch;minrev=3646;maxrev=4171"
 
recipes/perl/perl_5.10.1.bb +1 -1
index c22ecd7..86b08dc 100644
@@ -129,7 +129,7 @@ do_install() {
                    -e "s,${STAGING_LIBDIR},${libdir},g" \
                    -e "s,${STAGING_BINDIR},${bindir},g" \
                    -e "s,${STAGING_INCDIR},${includedir},g" \
-                   -e "s,${CROSS_DIR}${base_bindir}/,,g" \
+                   -e "s,${STAGING_DIR_NATIVE}${prefix_native}${base_bindir}/,,g" \
                 ${D}${bindir}/h2xs \
                 ${D}${bindir}/h2ph \
                 ${D}${datadir}/perl/${PV}/pod/*.pod \
recipes/perl/perl_5.8.8.bb +1 -1
index f09360f..c73fe4e 100644
@@ -135,7 +135,7 @@ do_install() {
                    -e "s,${STAGING_LIBDIR},${libdir},g" \
                    -e "s,${STAGING_BINDIR},${bindir},g" \
                    -e "s,${STAGING_INCDIR},${includedir},g" \
-                   -e "s,${CROSS_DIR}${base_bindir}/,,g" \
+                   -e "s,${STAGING_DIR_NATIVE}${prefix_native}${base_bindir}/,,g" \
                 ${D}${bindir}/h2xs \
                 ${D}${bindir}/h2ph \
                 ${D}${datadir}/perl/${PV}/pod/*.pod \
recipes/phoneme/phoneme-advanced.inc +1 -1
index a74bc04..9df61a6 100644
@@ -66,7 +66,7 @@ do_configure() {
 
   pmo "# Java toolchain binaries"
   pmo JDK_HOME /dev/null
-  pmo CVM_TARGET_TOOLS_PREFIX ${CROSS_DIR}/bin/
+  pmo CVM_TARGET_TOOLS_PREFIX ${STAGING_DIR_NATIVE}${prefix_native}/bin/
   pmo CVM_JAVA java
   pmo CVM_JAVAC javac
   pmo CVM_JAVADOC true
recipes/qi/qi.inc +1 -1
index 0b5451a..f9d4f2e 100644
@@ -21,7 +21,7 @@ BUILD_DATE=\$(shell date --iso-8601=seconds)
 # has been built. If it bails out with something like: "| arm-linux-ld: 4.3.3: No such file or directory"
 # then you need to remove all previously built toolchain directories out of the cross library path.
 GCCV="`${CC} -dumpversion`"
-COMPILER_LIB_PATH_PRE=${CROSS_DIR}/lib/gcc/${TARGET_SYS}/$(GCCV)
+COMPILER_LIB_PATH_PRE=${STAGING_DIR_NATIVE}${prefix_native}/lib/gcc/${TARGET_SYS}/$(GCCV)
 COMPILER_LIB_PATH=\$(COMPILER_LIB_PATH_PRE)/\$(shell ls \$(COMPILER_LIB_PATH_PRE))
 
 AS=${AS}
recipes/uclibc/bfin-uclibc_svn.bb +1 -1
index 2757fc2..954d10d 100644
@@ -20,7 +20,7 @@ COMPATIBLE_HOST = "bfin.*-uclinux"
 
 #as stated above, uclibc needs real kernel-headers
 #however: we can't depend on virtual/kernel when nptl hits due to depends deadlocking ....
-KERNEL_SOURCE = "${CROSS_DIR}/${TARGET_SYS}"
+KERNEL_SOURCE = "${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}"
 
 SRC_URI = "svn://sources.blackfin.uclinux.org/toolchain/trunk;module=uClibc "
 SRC_URI += "file://uClibc.machine file://uClibc.distro"
recipes/wvstreams/wvstreams_4.2.2.bb +1 -1
index 83f97be..4358ec1 100644
@@ -12,7 +12,7 @@ SRC_URI = "http://ftp.de.debian.org/debian/pool/main/w/wvstreams/${PN}_${PV}.ori
 
 inherit autotools pkgconfig
 
-LDFLAGS_append = " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS_append = " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 EXTRA_AUTORECONF += " -I${S}/gnulib/m4"
 EXTRA_OECONF = " --without-tcl --without-qt --without-pam"
recipes/wvstreams/wvstreams_4.4.1.bb +1 -1
index fa865c7..4506b05 100644
@@ -14,7 +14,7 @@ SRC_URI = "http://wvstreams.googlecode.com/files/${PN}-${PV}.tar.gz \
 
 inherit autotools pkgconfig
 
-LDFLAGS_append = " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS_append = " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 EXTRA_AUTORECONF += " -I${S}/gnulib/m4"
 EXTRA_OECONF = " --without-tcl --without-qt --without-pam"
recipes/wvstreams/wvstreams_4.6.bb +1 -1
index a52c284..eb70fd2 100644
@@ -8,7 +8,7 @@ SRC_URI = "http://wvstreams.googlecode.com/files/${PN}-${PV}.tar.gz \
 
 inherit autotools pkgconfig
 
-LDFLAGS_append = " -Wl,-rpath-link,${CROSS_DIR}/${TARGET_SYS}/lib"
+LDFLAGS_append = " -Wl,-rpath-link,${STAGING_DIR_NATIVE}${prefix_native}/${TARGET_SYS}/lib"
 
 EXTRA_OECONF = " --without-tcl --without-qt --without-pam"
 
Signature · 2 lines
Tom Rini
Mentor Graphics Corporation
author
#7 lore raw

PATCH 4/4 sanity.bbclass, abi_version.conf: Bump the ABI to inform that cross has died.

In reply to Khem Raj

* tmpdir layout is changed bump ABI version to force a rebuild.

---
 classes/sanity.bbclass |    2 ++
 conf/abi_version.conf  |    2 +-
 2 files changed, 3 insertions(+), 1 deletions(-)
classes/sanity.bbclass +2 -0
index 8eb7453..cff415a 100644
@@ -149,6 +149,8 @@ def check_sanity(e):
 			os.system(bb.data.expand("cd ${TMPDIR}/stamps; for i in */*do_populate_staging; do new=`echo $i | sed -e 's/do_populate_staging/do_populate_sysroot/'`; mv $i $new; done", e.data))
 			f = file(abifile, "w")
 			f.write(current_abi)
+		elif abi == "5" and current_abi != "5":
+			messages = messages + "Staging layout has changed. The cross directory has been deprecated and cross packages are now built under the native sysroot.\nThis requires a rebuild.\n"
 		elif (abi != current_abi):
 			# Code to convert from one ABI to another could go here if possible.
 			messages = messages + "Error, TMPDIR has changed ABI (%s to %s) and you need to either rebuild, revert or adjust it at your own risk.\n" % (abi, current_abi)
conf/abi_version.conf +1 -1
index 92b6b58..a59abf6 100644
@@ -4,7 +4,7 @@
 # that breaks the format and have been previously discussed on the mailing list 
 # with general agreement from the core team.
 #
-OELAYOUT_ABI = "4"
+OELAYOUT_ABI = "5"
 
 #
 # DISTRO_PR allows us to regenerate all packages when a fundamental change is
Signature · 1 line
1.7.1
Acked-by on v1 4/4
#8 lore raw

Re: [PATCH 4/4] sanity.bbclass, abi_version.conf: Bump the ABI to inform that cross has died.

Quoted 3 lines · Khem Raj

* tmpdir layout is changed bump ABI version to force a rebuild.

Quoted 31 lines
---
 classes/sanity.bbclass |    2 ++
 conf/abi_version.conf  |    2 +-
 2 files changed, 3 insertions(+), 1 deletions(-)
classes/sanity.bbclass +2 -0
index 8eb7453..cff415a 100644
@@ -149,6 +149,8 @@ def check_sanity(e):
 			os.system(bb.data.expand("cd ${TMPDIR}/stamps; for i in */*do_populate_staging; do new=`echo $i | sed -e 's/do_populate_staging/do_populate_sysroot/'`; mv $i $new; done", e.data))
 			f = file(abifile, "w")
 			f.write(current_abi)
+		elif abi == "5" and current_abi != "5":
+			messages = messages + "Staging layout has changed. The cross directory has been deprecated and cross packages are now built under the native sysroot.\nThis requires a rebuild.\n"
 		elif (abi != current_abi):
 			# Code to convert from one ABI to another could go here if possible.
 			messages = messages + "Error, TMPDIR has changed ABI (%s to %s) and you need to either rebuild, revert or adjust it at your own risk.\n" % (abi, current_abi)
conf/abi_version.conf +1 -1
index 92b6b58..a59abf6 100644
@@ -4,7 +4,7 @@
 # that breaks the format and have been previously discussed on the mailing list 
 # with general agreement from the core team.
 #
-OELAYOUT_ABI = "4"
+OELAYOUT_ABI = "5"
 
 #
 # DISTRO_PR allows us to regenerate all packages when a fundamental change is
Signature · 2 lines
Tom Rini
Mentor Graphics Corporation
#9 lore raw
In reply to Khem Raj
Quoted 8 lines · Khem Raj

Hi

The following 4 patches are based on Jushua's work in poky to get rid of cross dir and install the toolchain in native sysroot.

I have done native-sdk-builds for uclibc and eglibc. It could build the images and the images booted fine in qemu on mips and arm.

Quoted 6 lines

I would appreciate if someone could lend a hand in testing these patches

And as we have changed tmpdir layout with this patch I have also bumped ABI which means tmp has to be nuked before you try these patches.

Please review/ack/nack

Thanks alot for doing this! I've tested meta-toolchain + beagleboard on angstrom and minimal, acks coming.

Signature · 2 lines
Tom Rini
Mentor Graphics Corporation
#10 lore raw
In reply to Khem Raj
Quoted 6 lines · Khem Raj

The following 4 patches are based on Jushua's work in poky to get rid of cross dir and install the toolchain in native sysroot.

I have done native-sdk-builds for uclibc and eglibc. It could build the images and the images booted fine in qemu on mips and arm.

Quoted 6 lines

I would appreciate if someone could lend a hand in testing these patches

And as we have changed tmpdir layout with this patch I have also bumped ABI which means tmp has to be nuked before you try these patches.

Please review/ack/nack

Thanks for looking at this, its something I've wanted to get to for a while but haven't managed so far. Consider this an ack from me!

Cheers,

Richard

#11 lore raw
Quoted 10 lines · Richard Purdie
Quoted 4 lines · Khem Raj

The following 4 patches are based on Jushua's work in poky to get rid of cross dir and install the toolchain in native sysroot.

I have done native-sdk-builds for uclibc and eglibc. It could build the

images

Quoted 4 lines

and the images booted fine in qemu on mips and arm.

I would appreciate if someone could lend a hand in testing these patches

Quoted 8 lines
Quoted 1 line

And as we have changed tmpdir layout with this patch I have also bumped

ABI

Quoted 3 lines

which means tmp has to be nuked before you try these patches.

Please review/ack/nack

Thanks for looking at this, its something I've wanted to get to for a while but haven't managed so far. Consider this an ack from me!

Ack from me too, test builds work fine, this is a lovely change we've been wanting to see for a while now, nicely done pulling it over from the poky bits.

Signature · 5 lines
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics
Acked-by
#12 lore raw
Quoted 18 lines · Chris Larson
Quoted 16 lines · Richard Purdie
Quoted 4 lines · Khem Raj

The following 4 patches are based on Jushua's work in poky to get rid of cross dir and install the toolchain in native sysroot.

I have done native-sdk-builds for uclibc and eglibc. It could build the

images

Quoted 5 lines

and the images booted fine in qemu on mips and arm.

I would appreciate if someone could lend a hand in testing these patches

And as we have changed tmpdir layout with this patch I have also bumped

ABI

Quoted 3 lines

which means tmp has to be nuked before you try these patches.

Please review/ack/nack

Quoted 7 lines
Quoted 2 lines

Thanks for looking at this, its something I've wanted to get to for a while but haven't managed so far. Consider this an ack from me!

Ack from me too, test builds work fine, this is a lovely change we've been wanting to see for a while now, nicely done pulling it over from the poky bits.

SHR/om-gta02
Angstrom/spitz

also built ok here, thanks!

I guess that it would be difficult/dangerous to try to keep backward compatiblity and move it without abi_version change (as staging->sysroots was), right? But I'm OK with rebuilding.

For whole patchset:

Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]
Acked-by on the v1 series
#13 lore raw
In reply to Khem Raj

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 8 lines · Khem Raj

Hi

The following 4 patches are based on Jushua's work in poky to get rid of cross dir and install the toolchain in native sysroot.

I have done native-sdk-builds for uclibc and eglibc. It could build the images and the images booted fine in qemu on mips and arm.

Quoted 6 lines

I would appreciate if someone could lend a hand in testing these patches

And as we have changed tmpdir layout with this patch I have also bumped ABI which means tmp has to be nuked before you try these patches.

Please review/ack/nack

A quick test didn't show big problems (or little ones), so:

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)

iD8DBQFMSFuiMkyGM64RGpERAglXAJ9yESk18e5PmHNlo5QgxlZp2fzBQQCfYuZq LC5ebMKzuLJeJAmqES18Pt8=
=U2q8
-----END PGP SIGNATURE-----

#14 lore raw
In reply to Khem Raj

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 8 lines · Khem Raj

Hi

The following 4 patches are based on Jushua's work in poky to get rid of cross dir and install the toolchain in native sysroot.

I have done native-sdk-builds for uclibc and eglibc. It could build the images and the images booted fine in qemu on mips and arm.

Quoted 6 lines

I would appreciate if someone could lend a hand in testing these patches

And as we have changed tmpdir layout with this patch I have also bumped ABI which means tmp has to be nuked before you try these patches.

Please review/ack/nack

There is a BIG problem with these patches, they break multimachine builds.

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

I see 2 courses of action to fix this quickly:

1) add ${TARGET_SYS} back, bump ABI
2) revert these patches, bump ABI

So, what do other people think?

regards,

Koen
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)

iD8DBQFMSUP9MkyGM64RGpERAkkbAKCbMy47668egFF707rfNYNsiKSSKQCcDpbn 53k+LcpMKzu2x8uwQUbqrl0=
=Hy7k
-----END PGP SIGNATURE-----

#15 lore raw
Quoted 8 lines · Koen Kooi

There is a BIG problem with these patches, they break multimachine builds.

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

Quoted 6 lines

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

Which are the actual binaries that collide? I would have thought that everything which gets installed into the cross bindir ought to be prefixed with TARGET_SYS (i.e. usr/bin/armv7a-angstrom-linux-gcc, etc).

p.

#16 lore raw

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 11 lines · Phil Blundell
Quoted 10 lines · Koen Kooi

There is a BIG problem with these patches, they break multimachine builds.

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

The new situation has:

Quoted 8 lines
Quoted 4 lines

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

Which are the actual binaries that collide? I would have thought that everything which gets installed into the cross bindir ought to be prefixed with TARGET_SYS (i.e. usr/bin/armv7a-angstrom-linux-gcc, etc).

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I don't know if that solves the binutils-cross problem[1], though.

regards,

Koen

[1] http://thread.gmane.org/gmane.comp.handhelds.openembedded/34685
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)

iD8DBQFMSU6mMkyGM64RGpERAt9ZAJ4i7784CSoa8MtBrAR0obTqY/M1AwCeLgCf fVax6pw0ubR9Iq8HKw08CUM=
=TQ8M
-----END PGP SIGNATURE-----

#17 lore raw
Quoted 20 lines · Koen Kooi

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 16 lines · Phil Blundell
Quoted 14 lines · Koen Kooi

There is a BIG problem with these patches, they break multimachine builds.

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

Quoted 6 lines
Quoted 3 lines

Which are the actual binaries that collide? I would have thought that everything which gets installed into the cross bindir ought to be prefixed with TARGET_SYS (i.e. usr/bin/armv7a-angstrom-linux-gcc, etc).

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

If that doesn't help which I suspect it won't, my gut instinct is to add a architecture specific directory under bin for the cross bits. This could be as simple as changing bindir in cross.bbclass.

Quoted 5 lines

I don't know if that solves the binutils-cross problem[1], though.

Koen

[1] http://thread.gmane.org/gmane.comp.handhelds.openembedded/34685

Is that libiberty.a file actually useful or could we just stop binutils-cross installing it?

Cheers,

Richard

#18 lore raw

2010/7/23 Richard Purdie <[email protected]>

Quoted 26 lines · Koen Kooi
Quoted 6 lines

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 2 lines · Phil Blundell
Quoted 1 line · Koen Kooi

There is a BIG problem with these patches, they break multimachine

builds.

Quoted 18 lines
Quoted 17 lines
Quoted 7 lines

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

Quoted 6 lines

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

Which are the actual binaries that collide? I would have thought that everything which gets installed into the cross bindir ought to be prefixed with TARGET_SYS (i.e. usr/bin/armv7a-angstrom-linux-gcc, etc).

Quoted 9 lines
Quoted 2 lines

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

I've been pondering if TARGET_ARCH should be the real arch (like armv7a) and whether adjacent to that there should be a TARGET_ARCH_FAMILY or so.

Changing TARGET_ARCH to armv7a without other changes definitely is going to break things.
There are 110 .bb files that reference TARGET_ARCH

the last two lines of the grep read:

xqt2/xqt2_20060509.bb:    if [ ${TARGET_ARCH} == "arm" ]; then
xqt/xqt_0.0.9.bb:    if [ ${TARGET_ARCH} == "arm" ]; then

so these are definitely not going to fly

for some other of the 110 recipes the change is harmless (e.g. because they compare to "mips" in gcc-common.inc)
for most others I cannot judge this, e.g. because the value is passed to configure.

unrelated side note:
while grepping I noticed the existence of dirs like linux-uml and linux-atm. These contain kernel recipes.
Shouldn't these be in linux recipes dir? (or alternately shouldn't there be also things like linux-omap and linux-nios2).

frans

Quoted 24 lines

If that doesn't help which I suspect it won't, my gut instinct is to add a architecture specific directory under bin for the cross bits. This could be as simple as changing bindir in cross.bbclass.

Quoted 5 lines

I don't know if that solves the binutils-cross problem[1], though.

Koen

[1] http://thread.gmane.org/gmane.comp.handhelds.openembedded/34685

Is that libiberty.a file actually useful or could we just stop binutils-cross installing it?

Cheers,

Richard

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

author
#19 lore raw
Quoted 38 lines · Frans Meulenbroeks

2010/7/23 Richard Purdie <[email protected]>

Quoted 26 lines · Koen Kooi
Quoted 6 lines

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 2 lines · Phil Blundell
Quoted 1 line · Koen Kooi

There is a BIG problem with these patches, they break multimachine

builds.

Quoted 18 lines
Quoted 17 lines
Quoted 7 lines

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

Quoted 6 lines

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

Which are the actual binaries that collide?  I would have thought that everything which gets installed into the cross bindir ought to be prefixed with TARGET_SYS (i.e. usr/bin/armv7a-angstrom-linux-gcc, etc).

Quoted 9 lines
Quoted 2 lines

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

Quoted 5 lines

I've been pondering if TARGET_ARCH should be the real arch (like armv7a) and whether adjacent to that there should be a TARGET_ARCH_FAMILY or so.

Changing TARGET_ARCH to armv7a without other changes definitely is going to break things.

maybe we should not change TARGET_ARCH but use FEED_ARCH to construct TARGET_SYS

Quoted 50 lines

There are 110 .bb files that reference TARGET_ARCH

the last two lines of the grep read:
xqt2/xqt2_20060509.bb:    if [ ${TARGET_ARCH} == "arm" ]; then xqt/xqt_0.0.9.bb:    if [ ${TARGET_ARCH} == "arm" ]; then so these are definitely not going to fly

for some other of the 110 recipes the change is harmless (e.g. because they compare to "mips" in gcc-common.inc)
for most others I cannot judge this, e.g. because the value is passed to configure.

unrelated side note:
while grepping I noticed the existence of dirs like linux-uml and linux-atm. These contain kernel recipes.
Shouldn't these be in linux recipes dir? (or alternately shouldn't there be also things like linux-omap and linux-nios2).

frans

Quoted 15 lines

If that doesn't help which I suspect it won't, my gut instinct is to add a architecture specific directory under bin for the cross bits. This could be as simple as changing bindir in cross.bbclass.

Quoted 5 lines

I don't know if that solves the binutils-cross problem[1], though.

Koen

[1] http://thread.gmane.org/gmane.comp.handhelds.openembedded/34685

Is that libiberty.a file actually useful or could we just stop binutils-cross installing it?

Cheers,

Quoted 9 lines

Richard

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

#20 lore raw
Quoted 47 lines · Khem Raj
Quoted 25 lines · Frans Meulenbroeks

2010/7/23 Richard Purdie <[email protected]>

Quoted 23 lines · Koen Kooi
Quoted 6 lines

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 2 lines · Phil Blundell
Quoted 1 line · Koen Kooi

There is a BIG problem with these patches, they break multimachine

builds.

Quoted 15 lines
Quoted 15 lines
Quoted 7 lines

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

Quoted 6 lines

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

Which are the actual binaries that collide? I would have thought

that

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

everything which gets installed into the cross bindir ought to be prefixed with TARGET_SYS (i.e. usr/bin/armv7a-angstrom-linux-gcc,

etc).

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

It's all 'arm-angstrom-foo', I was just about to make the suggestion

to

Quoted 10 lines
Quoted 8 lines
Quoted 1 line

change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

I've been pondering if TARGET_ARCH should be the real arch (like armv7a)

and

Quoted 2 lines

whether adjacent to that there should be a TARGET_ARCH_FAMILY or so.

Quoted 7 lines
Quoted 1 line

Changing TARGET_ARCH to armv7a without other changes definitely is going

to

Quoted 1 line

break things.

maybe we should not change TARGET_ARCH but use FEED_ARCH to construct TARGET_SYS

Using a variable from packaging / rootfs creation as a field passed to configure at build time strikes me as a terrible idea.

Signature · 5 lines
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics
author
#21 lore raw
Quoted 54 lines · Chris Larson
Quoted 52 lines · Khem Raj
Quoted 25 lines · Frans Meulenbroeks

2010/7/23 Richard Purdie <[email protected]>

Quoted 23 lines · Koen Kooi
Quoted 6 lines

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 2 lines · Phil Blundell
Quoted 1 line · Koen Kooi

There is a BIG problem with these patches, they break multimachine

builds.

Quoted 15 lines
Quoted 15 lines
Quoted 7 lines

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

Quoted 6 lines

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

Which are the actual binaries that collide? I would have thought

that

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

everything which gets installed into the cross bindir ought to be prefixed with TARGET_SYS (i.e. usr/bin/armv7a-angstrom-linux-gcc,

etc).

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

It's all 'arm-angstrom-foo', I was just about to make the suggestion

to

Quoted 10 lines
Quoted 8 lines
Quoted 1 line

change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

I've been pondering if TARGET_ARCH should be the real arch (like armv7a)

and

Quoted 3 lines

whether adjacent to that there should be a TARGET_ARCH_FAMILY or so.

Changing TARGET_ARCH to armv7a without other changes definitely is going

to

Quoted 1 line

break things.

Quoted 6 lines
Quoted 2 lines

maybe we should not change TARGET_ARCH but use FEED_ARCH to construct TARGET_SYS

Using a variable from packaging / rootfs creation as a field passed to configure at build time strikes me as a terrible idea.

we have MULTIMACH_* variables in bitbake.conf I have done this patch using them. I trying a meta-toolchain build lets see

-Khem

Quoted 10 lines
Signature · 9 lines
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
classes/cross.bbclass +1 -1
index 75b2abe..cadf245 100644
@@ -8,7 +8,7 @@ EXCLUDE_FROM_WORLD = "1"
 # In order to keep TARGET_PREFIX decoupled from TARGET_SYS, let's force the
 # binary names to match the former, rather than relying on autoconf's implicit
 # prefixing based on the latter.
-EXTRA_OECONF_append = " --program-prefix=${TARGET_PREFIX}"
+EXTRA_OECONF_append = " --program-prefix=${MULTIMACH_TARGET_PREFIX}"
 
 # Save PACKAGE_ARCH before changing HOST_ARCH
 OLD_PACKAGE_ARCH := "${PACKAGE_ARCH}"
conf/bitbake.conf +1 -0
index 748abba..1564f10 100644
@@ -135,6 +135,7 @@ PACKAGE_ARCHS = "all any noarch ${TARGET_ARCH} ${PACKAGE_EXTRA_ARCHS} ${MACHINE}
 MULTIMACH_ARCH = "${PACKAGE_ARCH}"
 MULTIMACH_TARGET_SYS = "${MULTIMACH_ARCH}${TARGET_VENDOR}-${TARGET_OS}"
 MULTIMACH_HOST_SYS = "${MULTIMACH_ARCH}${HOST_VENDOR}-${HOST_OS}"
+MULTIMACH_TARGET_PREFIX = "${MULTIMACH_TARGET_SYS}-"
 BASEPKG_HOST_SYS = "${BASE_PACKAGE_ARCH}${HOST_VENDOR}-${HOST_OS}"
 BASEPKG_TARGET_SYS = "${BASE_PACKAGE_ARCH}${TARGET_VENDOR}-${TARGET_OS}"
 
author
#22 lore raw
In reply to Frans Meulenbroeks
Quoted 38 lines · Frans Meulenbroeks

2010/7/23 Richard Purdie <[email protected]>

Quoted 26 lines · Koen Kooi
Quoted 6 lines

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 2 lines · Phil Blundell
Quoted 1 line · Koen Kooi

There is a BIG problem with these patches, they break multimachine

builds.

Quoted 18 lines
Quoted 17 lines
Quoted 7 lines

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

Quoted 6 lines

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

Which are the actual binaries that collide?  I would have thought that everything which gets installed into the cross bindir ought to be prefixed with TARGET_SYS (i.e. usr/bin/armv7a-angstrom-linux-gcc, etc).

Quoted 9 lines
Quoted 2 lines

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

Quoted 6 lines

I've been pondering if TARGET_ARCH should be the real arch (like armv7a) and whether adjacent to that there should be a TARGET_ARCH_FAMILY or so.

Changing TARGET_ARCH to armv7a without other changes definitely is going to break things.
There are 110 .bb files that reference TARGET_ARCH

right. I am using MULTIMACH_ARCH (may be it should be called TARGET_SUB_ARCH) to construct
all canonical names. Which should leave TARGET_ARCH unaffected at the same time help us to have multiple toolchains co-exist.
I am trying a build where the HOST_SYS and TARGET_SYS will then use this var. lets see where I end up.

Quoted 49 lines

the last two lines of the grep read:
xqt2/xqt2_20060509.bb:    if [ ${TARGET_ARCH} == "arm" ]; then xqt/xqt_0.0.9.bb:    if [ ${TARGET_ARCH} == "arm" ]; then so these are definitely not going to fly

for some other of the 110 recipes the change is harmless (e.g. because they compare to "mips" in gcc-common.inc)
for most others I cannot judge this, e.g. because the value is passed to configure.

unrelated side note:
while grepping I noticed the existence of dirs like linux-uml and linux-atm. These contain kernel recipes.
Shouldn't these be in linux recipes dir? (or alternately shouldn't there be also things like linux-omap and linux-nios2).

frans

Quoted 15 lines

If that doesn't help which I suspect it won't, my gut instinct is to add a architecture specific directory under bin for the cross bits. This could be as simple as changing bindir in cross.bbclass.

Quoted 5 lines

I don't know if that solves the binutils-cross problem[1], though.

Koen

[1] http://thread.gmane.org/gmane.comp.handhelds.openembedded/34685

Is that libiberty.a file actually useful or could we just stop binutils-cross installing it?

Cheers,

Quoted 9 lines

Richard

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

author
#23 lore raw
Quoted 19 lines · Khem Raj
Quoted 17 lines · Frans Meulenbroeks

2010/7/23 Richard Purdie <[email protected]>

Quoted 15 lines · Koen Kooi
Quoted 6 lines

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 2 lines · Phil Blundell
Quoted 1 line · Koen Kooi

There is a BIG problem with these patches, they break multimachine

builds.

Quoted 7 lines
Quoted 7 lines
Quoted 7 lines

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

I have a half baked patch to get the above semantics like what poky did its not working
and its getting uglier. I dont feel good about it.
IMO having a new var like TARGET_SUB_ARCH point to sub-family (armv5te etc.) and later
use it to form all prefixes etc would be cleaner and easier to implement and maintain.
the limitation would be that you wont be able to have different version of toolchain components
for two different machines based on same sub-arch e.g. (qemuarm and omap5912osk both are based on
armv5te so one has to use same version of toolchain components for these kind of scenarios in a
multimachine build setup.

Therefore I would propose either we backout these patches for now or do single machine builds
in meantime we develop the solution.

-Khem

#24 lore raw
In reply to Richard Purdie
Quoted 9 lines · Richard Purdie
Quoted 2 lines · Koen Kooi

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

config.sub will generally not accept something like armv7a-*

If OE had not offered the vendor part of the arch strings to distros, it could have
been solved by (in this case) using arm-v7a-foo ...

/Esben

#25 lore raw

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 8 lines · Esben Haabendal
Quoted 7 lines · Richard Purdie
Quoted 2 lines · Koen Kooi

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

Quoted 8 lines
Quoted 2 lines

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

config.sub will generally not accept something like armv7a-*

If OE had not offered the vendor part of the arch strings to distros, it could have
been solved by (in this case) using arm-v7a-foo ...

Actually not, since that would break external toolchains. -----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)

iD8DBQFMSWovMkyGM64RGpERAg1CAKC5vOFH/cNptjp5FMAz0eDpvp2YtACfaU5V cHrMjEFU8rRlDZhNXw5NTns=
=JjxT
-----END PGP SIGNATURE-----

#26 lore raw
In reply to Esben Haabendal
Quoted 1 line · Esben Haabendal

config.sub will generally not accept something like armv7a-*

That's probably true, but it ought to accept armv7a-*-* (and has done for about fifteen years, so I expect almost all packages should now have picked up that change). I think OE always uses the triple so there oughtn't to be any problem in practice.

Quoted 3 lines

If OE had not offered the vendor part of the arch strings to distros, it could have
been solved by (in this case) using arm-v7a-foo ...

That doesn't sound very wholesome. I don't think 'v7a' is really a vendor name by any stretch of the imagination.

p.

#27 lore raw
Quoted 7 lines · Phil Blundell
Quoted 1 line · Esben Haabendal

config.sub will generally not accept something like armv7a-*

That's probably true, but it ought to accept armv7a-*-* (and has done for about fifteen years, so I expect almost all packages should now have picked up that change). I think OE always uses the triple so there oughtn't to be any problem in practice.

With tune-atom.inc active you'd have core2-*-* which I suspect config.sub will not accept. The point is the names we choose for sets of optimisation flags are not necessarily going to map well to config.sub and we shouldn't be crossing what are currently two independent namespaces...

Cheers,

Richard

#28 lore raw
Quoted 9 lines · Richard Purdie
Quoted 7 lines · Phil Blundell
Quoted 1 line · Esben Haabendal

config.sub will generally not accept something like armv7a-*

That's probably true, but it ought to accept armv7a-*-* (and has done for about fifteen years, so I expect almost all packages should now have picked up that change).  I think OE always uses the triple so there oughtn't to be any problem in practice.

Quoted 5 lines

With tune-atom.inc active you'd have core2-*-* which I suspect config.sub will not accept. The point is the names we choose for sets of optimisation flags are not necessarily going to map well to config.sub and we shouldn't be crossing what are currently two independent namespaces...

Definitely not.

The question is why these two namespaces has to be independent. But nevermind, I am just rambling here.

/Esben

author
#29 lore raw
In reply to Richard Purdie
Quoted 9 lines · Richard Purdie
Quoted 7 lines · Phil Blundell
Quoted 1 line · Esben Haabendal

config.sub will generally not accept something like armv7a-*

That's probably true, but it ought to accept armv7a-*-* (and has done for about fifteen years, so I expect almost all packages should now have picked up that change).  I think OE always uses the triple so there oughtn't to be any problem in practice.

Quoted 5 lines

With tune-atom.inc active you'd have core2-*-* which I suspect config.sub will not accept. The point is the names we choose for sets of optimisation flags are not necessarily going to map well to config.sub and we shouldn't be crossing what are currently two independent namespaces...

if we want to be able to build per machine then we have to add put the tools under MACHINE dir in native sysroot
but subfamilies can be differentiated like arm5t, armv5teb, armv7 etc thats how far compiler/toolchains can
differentiate. There is no problem with two different architectures e.g. mips, arm

Quoted 11 lines

Cheers,

Richard

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

#30 lore raw
In reply to Richard Purdie
Quoted 6 lines · Richard Purdie
Quoted 2 lines · Koen Kooi

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

Ah, right, I see.

Quoted 2 lines

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

I can't think offhand of any bad thing that would result from doing that. It certainly might be worth a try.

On the other hand, I also can't think offhand of any significant way in which the gcc builds for different subarches are going to be different. The architecture selection is all done at run time using -march in CFLAGS, isn't it?

Quoted 2 lines

Is that libiberty.a file actually useful or could we just stop binutils-cross installing it?

No, it isn't useful.

p.

#31 lore raw
Quoted 8 lines · Phil Blundell
Quoted 6 lines · Richard Purdie
Quoted 2 lines · Koen Kooi

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

Quoted 7 lines

Ah, right, I see.

Quoted 2 lines

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

I can't think offhand of any bad thing that would result from doing that. It certainly might be worth a try.

config.sub was in my mind as Esben mentioned. Our siteinfo code will also probably get upset. Then there are the TARGET_SYS comparisons.

Quoted 4 lines

On the other hand, I also can't think offhand of any significant way in which the gcc builds for different subarches are going to be different. The architecture selection is all done at run time using -march in CFLAGS, isn't it?

Well, the libgcc and stdc++ generated are different so we can't use one build. I have so far failed to make gcc generate libgcc standalone as it makes some horrible build assumptions. Even generating libstdc++ standalone was fun in Poky but I have that working at least.

The reason things break is we code the default sysroot option into gcc. So if you start using the wrong one, you pull in the wrong kind of binaries and depending on your build order at best it results in unoptimised code and worst, the binaries won't run.

So in summary it'd be nice to have a single gcc per arch but we're not there yet.

Quoted 4 lines
Quoted 2 lines

Is that libiberty.a file actually useful or could we just stop binutils-cross installing it?

No, it isn't useful.

I'm testing some patches against poky which add an extra directory level in /usr/bin/. I've also patched binutils-cross to stop spewing excess bits all over the place. I'll report back how it goes.

Longer term there are probably better fixes but there are too many issues at present to do that.

Cheers,

Richard

#32 lore raw
Quoted 3 lines · Richard Purdie

I'm testing some patches against poky which add an extra directory level in /usr/bin/. I've also patched binutils-cross to stop spewing excess bits all over the place. I'll report back how it goes.

I got things fixed in Poky, pending more extensive testing which I haven't had time for yet. There are several things needed though:

a) Have gcc dump a load of symlinks into its libexec directory:

http://git.pokylinux.org/cgit.cgi/poky/commit/?id=bf8023237c6fe43781fa4ce0db00f2b08cab7817

This is so when it tries to find "as" (not TARGET_PREFIX-as) it will find the right ones. It means we don't need the duplicates from bintuils which always end up in a multimachine unsafe path which means we can then:

b) Kill off bits of binutils that don't make sense

http://git.pokylinux.org/cgit.cgi/poky/commit/?id=066535608e879c0327dfa874f3978d6cc15fa59f

and then

c) Create some extra path layers which hold the different toolchains. We have to split out bindir, libdir and libexec dir as they all contain varying amounts of potentially machine sensitive code (sysroot settings).

http://git.pokylinux.org/cgit.cgi/poky/commit/?id=66d7b58f224e55b70b80a01d451270b7de757885

Poky has the complication its using gcc-runtime which builds/packages the target gcc libs separately where it possibly can. I had to tweak things to account for this with some other patches and also make that multi arch safe. I think OE should be ok in this regard but something like:

http://git.pokylinux.org/cgit.cgi/poky/commit/?id=ab82312433f8a7eacd6ee90d3bc9e5153282ec3f

may be required due to the way gcc makes assumptions about paths.

Cheers,

Richard

author
#33 lore raw
In reply to Richard Purdie
Quoted 25 lines · Richard Purdie
Quoted 24 lines · Koen Kooi

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 19 lines · Phil Blundell
Quoted 8 lines · Koen Kooi

There is a BIG problem with these patches, they break multimachine builds.

The previous situation had:

cross/armv7a-angstrom-foo/usr/bin/
cross/armv5te-angstrom-foo/usr/bin/
etc

Quoted 6 lines

The new situation has:

x86_64-linux/usr/bin

So all the toolchains get dropped into the *same* directory, which breaks horribly.

Which are the actual binaries that collide?  I would have thought that everything which gets installed into the cross bindir ought to be prefixed with TARGET_SYS (i.e. usr/bin/armv7a-angstrom-linux-gcc, etc).

Quoted 8 lines
Quoted 2 lines

It's all 'arm-angstrom-foo', I was just about to make the suggestion to change it to 'armv7a-angstrom-foo' :)

I've just been talking to Koen about this. When building for armv7a, TARGET_ARCH which goes into TARGET_PREFIX and TARGET_SYS is "arm".

I suspect if we change TARGET_ARCH to be armv7a, nasty things will happen but I could be wrong.

I think it will be fine. I think this will be fine approach. If we think this is the way I can throw in a patch quickly.

Quoted 25 lines

If that doesn't help which I suspect it won't, my gut instinct is to add a architecture specific directory under bin for the cross bits. This could be as simple as changing bindir in cross.bbclass.

Quoted 5 lines

I don't know if that solves the binutils-cross problem[1], though.

Koen

[1] http://thread.gmane.org/gmane.comp.handhelds.openembedded/34685

Is that libiberty.a file actually useful or could we just stop binutils-cross installing it?

Cheers,

Richard

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

#34 lore raw
In reply to Koen Kooi
Quoted 1 line · Koen Kooi

There is a BIG problem with these patches, they break multimachine builds.

Yes, I see it now too after launching another machine with different arm version (armv4/armv7) in my SHR builddir (om-gta0[12] were fine because both using armv4).

ie binutils-cross versions are overwritten in sysroots/x86_64-linux/usr/arm-oe-linux-gnueabi/bin/ and last build wins.

Quoted 4 lines

I see 2 courses of action to fix this quickly:

1) add ${TARGET_SYS} back, bump ABI
2) revert these patches, bump ABI

Someone know how it's solved in poky? I'm reading git log there and don't see TARGET_SYS used for every cross lib/bin, so maybe they don't allow multimachine (multiarch) builds?

Regards,

Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]