summaryrefslogtreecommitdiff
path: root/meta/packages
diff options
context:
space:
mode:
Diffstat (limited to 'meta/packages')
-rw-r--r--meta/packages/meta/meta-toolchain.bb72
1 files changed, 36 insertions, 36 deletions
diff --git a/meta/packages/meta/meta-toolchain.bb b/meta/packages/meta/meta-toolchain.bb
index f7c372672..65b802f6b 100644
--- a/meta/packages/meta/meta-toolchain.bb
+++ b/meta/packages/meta/meta-toolchain.bb
@@ -10,7 +10,7 @@ SDK_OUTPUT2 = "${SDK_DIR}/image-extras"
SDK_DEPLOY = "${TMPDIR}/deploy/sdk"
IPKG_HOST = "opkg-cl -f ${IPKGCONF_SDK} -o ${SDK_OUTPUT}"
-IPKG_TARGET = "opkg-cl -f ${IPKGCONF_TARGET} -o ${SDK_OUTPUT}/${SDK_PREFIX}/${TARGET_SYS}"
+IPKG_TARGET = "opkg-cl -f ${IPKGCONF_TARGET} -o ${SDK_OUTPUT}/${SDKPATH}/${TARGET_SYS}"
TOOLCHAIN_HOST_TASK ?= "task-sdk-host"
TOOLCHAIN_TARGET_TASK ?= "task-poky-standalone-sdk-target task-poky-standalone-sdk-target-dbg"
@@ -25,7 +25,7 @@ do_populate_sdk() {
rm -rf ${SDK_OUTPUT2}
mkdir -p ${SDK_OUTPUT}
mkdir -p ${SDK_OUTPUT}${layout_libdir}/opkg/
- mkdir -p ${SDK_OUTPUT}/${SDK_PREFIX}/${TARGET_SYS}${layout_libdir}/opkg/
+ mkdir -p ${SDK_OUTPUT}/${SDKPATH}/${TARGET_SYS}${layout_libdir}/opkg/
rm -f ${IPKGCONF_TARGET}
touch ${IPKGCONF_TARGET}
@@ -45,39 +45,39 @@ do_populate_sdk() {
${IPKG_TARGET} update
${IPKG_TARGET} install ${TOOLCHAIN_TARGET_TASK}
- install -d ${SDK_OUTPUT}/${SDK_PREFIX}/usr/lib/opkg
- mv ${SDK_OUTPUT}/usr/lib/opkg/* ${SDK_OUTPUT}/${SDK_PREFIX}/usr/lib/opkg/
+ install -d ${SDK_OUTPUT}/${SDKPATH}/usr/lib/opkg
+ mv ${SDK_OUTPUT}/usr/lib/opkg/* ${SDK_OUTPUT}/${SDKPATH}/usr/lib/opkg/
rm -Rf ${SDK_OUTPUT}/usr/lib
- install -d ${SDK_OUTPUT}/${SDK_PREFIX}/${TARGET_SYS}/${layout_sysconfdir}
- install -m 0644 ${IPKGCONF_TARGET} ${IPKGCONF_SDK} ${SDK_OUTPUT}/${SDK_PREFIX}/${TARGET_SYS}/${layout_sysconfdir}/
+ install -d ${SDK_OUTPUT}/${SDKPATH}/${TARGET_SYS}/${layout_sysconfdir}
+ install -m 0644 ${IPKGCONF_TARGET} ${IPKGCONF_SDK} ${SDK_OUTPUT}/${SDKPATH}/${TARGET_SYS}/${layout_sysconfdir}/
- install -d ${SDK_OUTPUT}/${SDK_PREFIX}/${sysconfdir}
- install -m 0644 ${IPKGCONF_SDK} ${SDK_OUTPUT}/${SDK_PREFIX}/${sysconfdir}/
+ install -d ${SDK_OUTPUT}/${SDKPATH}/${sysconfdir}
+ install -m 0644 ${IPKGCONF_SDK} ${SDK_OUTPUT}/${SDKPATH}/${sysconfdir}/
# extract and store ipks, pkgdata and shlibs data
- target_pkgs=`cat ${SDK_OUTPUT}/${SDK_PREFIX}/${TARGET_SYS}/usr/lib/opkg/status | grep Package: | cut -f 2 -d ' '`
- mkdir -p ${SDK_OUTPUT2}/${SDK_PREFIX}/ipk/
- mkdir -p ${SDK_OUTPUT2}/${SDK_PREFIX}/pkgdata/runtime/
- mkdir -p ${SDK_OUTPUT2}/${SDK_PREFIX}/${TARGET_SYS}/shlibs/
+ target_pkgs=`cat ${SDK_OUTPUT}/${SDKPATH}/${TARGET_SYS}/usr/lib/opkg/status | grep Package: | cut -f 2 -d ' '`
+ mkdir -p ${SDK_OUTPUT2}/${SDKPATH}/ipk/
+ mkdir -p ${SDK_OUTPUT2}/${SDKPATH}/pkgdata/runtime/
+ mkdir -p ${SDK_OUTPUT2}/${SDKPATH}/${TARGET_SYS}/shlibs/
for pkg in $target_pkgs ; do
for arch in $revipkgarchs; do
pkgnames=${DEPLOY_DIR_IPK}/$arch/${pkg}_*_$arch.ipk
if [ -e $pkgnames ]; then
echo "Found $pkgnames"
- cp $pkgnames ${SDK_OUTPUT2}/${SDK_PREFIX}/ipk/
+ cp $pkgnames ${SDK_OUTPUT2}/${SDKPATH}/ipk/
orig_pkg=`opkg-list-fields $pkgnames | grep OE: | cut -d ' ' -f2`
pkg_subdir=$arch${TARGET_VENDOR}${@['-' + bb.data.getVar('TARGET_OS', d, 1), ''][bb.data.getVar('TARGET_OS', d, 1) == ('' or 'custom')]}
- mkdir -p ${SDK_OUTPUT2}/${SDK_PREFIX}/pkgdata/$pkg_subdir/runtime
- cp ${TMPDIR}/pkgdata/$pkg_subdir/$orig_pkg ${SDK_OUTPUT2}/${SDK_PREFIX}/pkgdata/$pkg_subdir/
+ mkdir -p ${SDK_OUTPUT2}/${SDKPATH}/pkgdata/$pkg_subdir/runtime
+ cp ${TMPDIR}/pkgdata/$pkg_subdir/$orig_pkg ${SDK_OUTPUT2}/${SDKPATH}/pkgdata/$pkg_subdir/
subpkgs=`cat ${TMPDIR}/pkgdata/$pkg_subdir/$orig_pkg | grep PACKAGES: | cut -b 10-`
for subpkg in $subpkgs; do
- cp ${TMPDIR}/pkgdata/$pkg_subdir/runtime/$subpkg ${SDK_OUTPUT2}/${SDK_PREFIX}/pkgdata/$pkg_subdir/runtime/
+ cp ${TMPDIR}/pkgdata/$pkg_subdir/runtime/$subpkg ${SDK_OUTPUT2}/${SDKPATH}/pkgdata/$pkg_subdir/runtime/
if [ -e ${TMPDIR}/pkgdata/$pkg_subdir/runtime/$subpkg.packaged ];then
- cp ${TMPDIR}/pkgdata/$pkg_subdir/runtime/$subpkg.packaged ${SDK_OUTPUT2}/${SDK_PREFIX}/pkgdata/$pkg_subdir/runtime/
+ cp ${TMPDIR}/pkgdata/$pkg_subdir/runtime/$subpkg.packaged ${SDK_OUTPUT2}/${SDKPATH}/pkgdata/$pkg_subdir/runtime/
fi
if [ -e ${STAGING_DIR_TARGET}/shlibs/$subpkg.list ]; then
- cp ${STAGING_DIR_TARGET}/shlibs/$subpkg.* ${SDK_OUTPUT2}/${SDK_PREFIX}/${TARGET_SYS}/shlibs/
+ cp ${STAGING_DIR_TARGET}/shlibs/$subpkg.* ${SDK_OUTPUT2}/${SDKPATH}/${TARGET_SYS}/shlibs/
fi
done
break
@@ -86,43 +86,43 @@ do_populate_sdk() {
done
# Fix or remove broken .la files
- for i in `find ${SDK_OUTPUT}/${SDK_PREFIX}/${TARGET_SYS} -name \*.la`; do
- sed -i -e "/^dependency_libs=/s,\([[:space:]']\)${layout_base_libdir},\1${SDK_PREFIX}/${TARGET_SYS}${layout_base_libdir},g" \
- -e "/^dependency_libs=/s,\([[:space:]']\)${layout_libdir},\1${SDK_PREFIX}/${TARGET_SYS}${layout_libdir},g" \
- -e "/^dependency_libs=/s,\-\([LR]\)${layout_base_libdir},-\1${SDK_PREFIX}/${TARGET_SYS}${layout_base_libdir},g" \
- -e "/^dependency_libs=/s,\-\([LR]\)${layout_libdir},-\1${SDK_PREFIX}/${TARGET_SYS}${layout_libdir},g" \
+ for i in `find ${SDK_OUTPUT}/${SDKPATH}/${TARGET_SYS} -name \*.la`; do
+ sed -i -e "/^dependency_libs=/s,\([[:space:]']\)${layout_base_libdir},\1${SDKPATH}/${TARGET_SYS}${layout_base_libdir},g" \
+ -e "/^dependency_libs=/s,\([[:space:]']\)${layout_libdir},\1${SDKPATH}/${TARGET_SYS}${layout_libdir},g" \
+ -e "/^dependency_libs=/s,\-\([LR]\)${layout_base_libdir},-\1${SDKPATH}/${TARGET_SYS}${layout_base_libdir},g" \
+ -e "/^dependency_libs=/s,\-\([LR]\)${layout_libdir},-\1${SDKPATH}/${TARGET_SYS}${layout_libdir},g" \
-e 's/^installed=yes$/installed=no/' $i
done
- rm -f ${SDK_OUTPUT}/${SDK_PREFIX}/lib/*.la
+ rm -f ${SDK_OUTPUT}/${SDKPATH}/lib/*.la
# Setup site file for external use
- siteconfig=${SDK_OUTPUT}/${SDK_PREFIX}/site-config
+ siteconfig=${SDK_OUTPUT}/${SDKPATH}/site-config
touch $siteconfig
for sitefile in ${CONFIG_SITE} ; do
cat $sitefile >> $siteconfig
done
# Create environment setup script
- script=${SDK_OUTPUT}/${SDK_PREFIX}/environment-setup
+ script=${SDK_OUTPUT}/${SDKPATH}/environment-setup
touch $script
- echo 'export PATH=${SDK_PREFIX}/bin:$PATH' >> $script
- echo 'export PKG_CONFIG_SYSROOT_DIR=${SDK_PREFIX}/${TARGET_SYS}' >> $script
- echo 'export PKG_CONFIG_PATH=${SDK_PREFIX}/${TARGET_SYS}${layout_libdir}/pkgconfig' >> $script
- echo 'export CONFIG_SITE=${SDK_PREFIX}/site-config' >> $script
+ echo 'export PATH=${SDKPATH}/bin:$PATH' >> $script
+ echo 'export PKG_CONFIG_SYSROOT_DIR=${SDKPATH}/${TARGET_SYS}' >> $script
+ echo 'export PKG_CONFIG_PATH=${SDKPATH}/${TARGET_SYS}${layout_libdir}/pkgconfig' >> $script
+ echo 'export CONFIG_SITE=${SDKPATH}/site-config' >> $script
echo 'export CC=${TARGET_PREFIX}gcc' >> $script
echo 'export CONFIGURE_FLAGS="--target=${TARGET_SYS} --host=${TARGET_SYS} --build=${BUILD_SYS}"' >> $script
if [ "${TARGET_OS}" = "darwin8" ]; then
- echo 'export TARGET_CFLAGS="-I${SDK_PREFIX}/${TARGET_SYS}${layout_includedir}"' >> $script
- echo 'export TARGET_LDFLAGS="-L${SDK_PREFIX}/${TARGET_SYS}${layout_libdir}"' >> $script
+ echo 'export TARGET_CFLAGS="-I${SDKPATH}/${TARGET_SYS}${layout_includedir}"' >> $script
+ echo 'export TARGET_LDFLAGS="-L${SDKPATH}/${TARGET_SYS}${layout_libdir}"' >> $script
# Workaround darwin toolchain sysroot path problems
- cd ${SDK_OUTPUT}${SDK_PREFIX}/${TARGET_SYS}/usr
+ cd ${SDK_OUTPUT}${SDKPATH}/${TARGET_SYS}/usr
ln -s /usr/local local
fi
- echo "alias opkg='LD_LIBRARY_PATH=${SDK_PREFIX}/lib ${SDK_PREFIX}/bin/opkg-cl -f ${SDK_PREFIX}/${sysconfdir}/opkg-sdk.conf -o ${SDK_PREFIX}'" >> $script
- echo "alias opkg-target='LD_LIBRARY_PATH=${SDK_PREFIX}/lib ${SDK_PREFIX}/bin/opkg-cl -f ${SDK_PREFIX}/${TARGET_SYS}${layout_sysconfdir}/opkg.conf -o ${SDK_PREFIX}/${TARGET_SYS}'" >> $script
+ echo "alias opkg='LD_LIBRARY_PATH=${SDKPATH}/lib ${SDKPATH}/bin/opkg-cl -f ${SDKPATH}/${sysconfdir}/opkg-sdk.conf -o ${SDKPATH}'" >> $script
+ echo "alias opkg-target='LD_LIBRARY_PATH=${SDKPATH}/lib ${SDKPATH}/bin/opkg-cl -f ${SDKPATH}/${TARGET_SYS}${layout_sysconfdir}/opkg.conf -o ${SDKPATH}/${TARGET_SYS}'" >> $script
# Add version information
- versionfile=${SDK_OUTPUT}/${SDK_PREFIX}/version
+ versionfile=${SDK_OUTPUT}/${SDKPATH}/version
touch $versionfile
echo 'Distro: ${DISTRO}' >> $versionfile
echo 'Distro Version: ${DISTRO_VERSION}' >> $versionfile