Factor ipkg index and conf file creation into package_ipk.bbclass

git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2637 311d38ba-8fff-0310-9ca6-ca027cbcb966
This commit is contained in:
Richard Purdie
2007-09-01 22:17:06 +00:00
parent a7c63ec482
commit c6938aad87
6 changed files with 88 additions and 52 deletions

View File

@@ -1,21 +1,15 @@
DESCRIPTION = "Meta package for building a installable toolchain"
LICENSE = "MIT"
DEPENDS = "ipkg-native ipkg-utils-native fakeroot-native sed-native"
PR = "r3"
inherit sdk
PACKAGES = ""
BUILD_ALL_DEPS = "1"
do_build[recrdeptask] = "do_build"
inherit sdk meta
SDK_DIR = "${WORKDIR}/sdk"
SDK_OUTPUT = "${SDK_DIR}/image"
SDK_DEPLOY = "${TMPDIR}/deploy/sdk"
IPKG_HOST = "ipkg-cl -f ${SDK_DIR}/ipkg-host.conf -o ${SDK_OUTPUT}"
IPKG_TARGET = "ipkg-cl -f ${SDK_DIR}/ipkg-target.conf -o ${SDK_OUTPUT}/${prefix}"
IPKG_HOST = "ipkg-cl -f ${IPKGCONF_SDK} -o ${SDK_OUTPUT}"
IPKG_TARGET = "ipkg-cl -f ${IPKGCONF_TARGET} -o ${SDK_OUTPUT}/${prefix}"
HOST_INSTALL = "task-poky-standalone-sdk-host"
@@ -30,20 +24,11 @@ do_populate_sdk() {
rm -rf ${SDK_OUTPUT}
mkdir -p ${SDK_OUTPUT}
cat <<EOF >${SDK_DIR}/ipkg-host.conf
src oe file:${DEPLOY_DIR_IPK}
EOF
cat <<EOF >${SDK_DIR}/ipkg-target.conf
src oe file:${DEPLOY_DIR_IPK}
EOF
ipkgarchs="${PACKAGE_ARCHS}"
priority=1
for arch in $ipkgarchs; do
echo "arch $arch $priority" >> ${SDK_DIR}/ipkg-target.conf
echo "arch ${BUILD_ARCH}-$arch-sdk $priority" >> ${SDK_DIR}/ipkg-host.conf
priority=$(expr $priority + 5)
package_generate_ipkg_conf
for arch in ${PACKAGE_ARCHS}; do
revipkgarchs="$arch $revipkgarchs"
done
done
rm -r ${SDK_OUTPUT}
mkdir -p ${SDK_OUTPUT}