summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKoen Kooi <koen@openembedded.org>2008-10-22 17:54:39 +0200
committerKoen Kooi <koen@openembedded.org>2008-10-22 17:54:39 +0200
commitf08faaf550d5b17887969473fd07f626ca50f6b3 (patch)
tree207d78a0d3c925e3da4ec5bee9424d6ff85e6d7b
parent4cd19c0dc67b9ef3abf32430f6d370d4d07a29c5 (diff)
codec-engine: commit latest work in progress
-rw-r--r--packages/dsplink/codec-engine_2.10.bb5
-rw-r--r--packages/dsplink/codec-engine_2.21.bb160
-rw-r--r--packages/dsplink/dsplink.inc4
-rw-r--r--packages/dsplink/ti-paths.inc2
4 files changed, 166 insertions, 5 deletions
diff --git a/packages/dsplink/codec-engine_2.10.bb b/packages/dsplink/codec-engine_2.10.bb
index cbf27a12c6..abfe2f24e6 100644
--- a/packages/dsplink/codec-engine_2.10.bb
+++ b/packages/dsplink/codec-engine_2.10.bb
@@ -5,8 +5,9 @@ RDEPENDS = "update-modules"
inherit module
-FILE_PR = "r7"
-PV = "2.10"
+# tconf from xdctools dislikes '.' in pwd :/
+PR = "r0"
+PV = "210"
# Get CE tarball from TI website, place in sources and calculate
# md5sum
diff --git a/packages/dsplink/codec-engine_2.21.bb b/packages/dsplink/codec-engine_2.21.bb
new file mode 100644
index 0000000000..4c75464a27
--- /dev/null
+++ b/packages/dsplink/codec-engine_2.21.bb
@@ -0,0 +1,160 @@
+DESCRIPTION = "Codec Engine for TI ARM/DSP processors"
+
+DEPENDS = "virtual/kernel perl-native"
+RDEPENDS = "update-modules"
+
+inherit module
+
+# tconf from xdctools dislikes '.' in pwd :/
+PR = "r0"
+PV = "221"
+
+# Get CE tarball from TI website, place in sources and calculate
+# md5sum
+# Look for tarball at https://www-a.ti.com/downloads/sds_support/targetcontent/CE/index.html
+
+SRC_URI = "http://install.tarball.in.source.dir/codec_engine_2_21_00_06.tar.gz \
+ "
+
+S = "${WORKDIR}/codec_engine_2_21_00_06"
+
+require ti-paths.inc
+
+PARALLEL_MAKE = ""
+do_compile() {
+ echo "MVTOOL_PREFIX=${TARGET_PREFIX}" > ${S}/Rules.make
+ echo "UCTOOL_PREFIX=${TARGET_PREFIX}" >> ${S}/Rules.make
+ echo "LINUXKERNEL_INSTALL_DIR=${STAGING_KERNEL_DIR}" >> ${S}/Rules.make
+
+ unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
+ cd ${S}/cetools/packages/ti/sdo/linuxutils/cmem
+
+ oe_runmake clean
+ oe_runmake KERNEL_PATH=${STAGING_KERNEL_DIR} \
+ KERNEL_SRC=${STAGING_KERNEL_DIR} \
+ KERNEL_VERSION=${KERNEL_VERSION} \
+ CC="${KERNEL_CC}" LD="${KERNEL_LD}" \
+ AR="${KERNEL_AR}" \
+ release
+ oe_runmake KERNEL_PATH=${STAGING_KERNEL_DIR} \
+ KERNEL_SRC=${STAGING_KERNEL_DIR} \
+ KERNEL_VERSION=${KERNEL_VERSION} \
+ CC="${KERNEL_CC}" LD="${KERNEL_LD}" \
+ AR="${KERNEL_AR}" \
+ debug
+ oe_runmake KERNEL_PATH=${STAGING_KERNEL_DIR} \
+ KERNEL_SRC=${STAGING_KERNEL_DIR} \
+ KERNEL_VERSION=${KERNEL_VERSION} \
+ CC="${KERNEL_CC}" LD="${KERNEL_LD}" \
+ AR="${KERNEL_AR}"
+
+ cd ${S}/cetools/packages/ti/bios/power
+ if ! [ -e omap3530 ] ; then tar xf ti_bios_power,omap3530_bld.tar ; fi
+ cd omap3530/lpm
+
+ sed -i -e s:/db/toolsrc/library/tools/vendors/mvl/arm/omap3/OMAP35x_SDK_0.9.7/src/linux/kernel_org/2.6_kernel:${STAGING_KERNEL_DIR}:g \
+ -e s:/db/toolsrc/library/tools/vendors/cs/arm/arm-2007q3/bin/arm-none-linux-gnueabi-:${TARGET_PREFIX}:g \
+ -e s:/db/atree/library/trees/power/power-d02x/imports:${STAGING_DIR_TARGET}:g \
+ Makefile
+
+ oe_runmake KERNEL_PATH=${STAGING_KERNEL_DIR} \
+ KERNEL_SRC=${STAGING_KERNEL_DIR} \
+ KERNEL_VERSION=${KERNEL_VERSION} \
+ CC="${KERNEL_CC}" LD="${KERNEL_LD}" \
+ AR="${KERNEL_AR}"
+
+ cd ${S}/examples
+ export CE_INSTALL_DIR=${S}
+ export XDC_INSTALL_DIR=${TIXDCTOOLSDIR}
+ export BIOS_INSTALL_DIR=${TITOOLSDIR}/${TIBIOSDIR}
+
+ sed -i -e s:/db/toolsrc/library/tools/vendors/cs/arm/arm-2007q3:${CROSS_DIR}:g \
+ -e s:/db/toolsrc/library/tools/vendors/ti/c6x/6.0.16/Linux:${TITOOLSDIR}/${TICGTOOLSDIR}:g \
+ -e s:/db/toolsrc/library/tools/vendors/opensource/gcc/4.1.0/Linux/gcc-4.1.0-glibc-2.3.6/i686-unknown-linux-gnu:/usr:g \
+ -e s:arm-none-linux-gnueabi-:${TARGET_PREFIX}:g \
+ -e 's:true, // build for uC Linux:false,:g' \
+ ${S}/examples/user.bld
+
+ sed -i -e s:/db/toolsrc/library/tools/vendors/ti/c6x/6.0.16/Linux:${TITOOLSDIR}/${TICGTOOLSDIR}:g \
+ xdcpaths.mak
+
+ for i in codecs extensions servers apps ; do
+ make -e -C ${S}/examples/ti/sdo/ce/examples/$i clean
+ make -e -C ${S}/examples/ti/sdo/ce/examples/$i
+ done
+
+}
+
+export DSPLIBS = "${S}/packages/ti/sdo/ce/utils/trace/lib/*.a* \
+ ${S}/packages/ti/sdo/ce/bioslog/lib/*.a* \
+ ${S}/packages/ti/sdo/ce/video/lib/*.a* \
+ ${S}/packages/ti/sdo/ce/audio/lib/*.a* \
+ ${S}/packages/ti/sdo/ce/speech/lib/*.a* \
+ ${S}/packages/ti/sdo/ce/lib/*.a* \
+ ${S}/packages/ti/sdo/ce/alg/lib/*.a* \
+ ${S}/cetools/packages/ti/sdo/fc/dman3/*.a* \
+ ${S}/cetools/packages/ti/sdo/fc/acpy3/*.a* \
+ ${S}/packages/ti/sdo/ce/osal/linux/lib/osal_linux_470.a* \
+ ${S}/packages/ti/sdo/ce/utils/xdm/lib/*.a* \
+ ${S}/cetools/packages/ti/sdo/utils/trace/lib/*.a* \
+ "
+
+do_install() {
+ unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
+ cd ${S}/cetools/packages/ti/sdo/linuxutils/cmem
+ oe_runmake install
+ install -d ${D}/lib/modules/${KERNEL_VERSION}/kernel/drivers/dsp
+ mv ${D}/cmemk.ko ${D}/lib/modules/${KERNEL_VERSION}/kernel/drivers/dsp
+ install -d ${D}/${base_sbindir}
+ cd ${D} ; mv apitest apitestd multi_process multi_processd translate translated ${D}/${base_sbindir}
+
+
+ install -d ${D}/${libdir}
+ for i in ${DSPLIBS}; do
+ install -m 0755 $i ${D}/${libdir}/ || true
+ done
+ install -m 0755 ${S}/cetools/packages/ti/sdo/linuxutils/cmem/lib/*.a ${D}/${libdir}
+}
+
+do_stage() {
+ install -d ${STAGING_LIBDIR}
+ for i in ${DSPLIBS} ; do
+ install -m 0755 $i ${STAGING_LIBDIR}/
+ ln -sf ${STAGING_LIBDIR}/$(basename $i | awk -F. '{print $1}').a470MV ${STAGING_LIBDIR}/$(basename $i | awk -F. '{print $1}').a || true
+ done
+
+ install -m 0755 ${S}/cetools/packages/ti/sdo/linuxutils/cmem/lib/*.a ${STAGING_LIBDIR}/
+
+ install -d ${STAGING_INCDIR}/codec-engine}
+
+ for header in $(find ${S}/cetools/packages/ -name "*.h") ; do
+ install -d ${STAGING_INCDIR}/codec-engine/$(dirname $header | sed s:${S}::g)
+ cp -pPr $header ${STAGING_INCDIR}/codec-engine/$(echo $header | sed s:${S}::g)
+ done
+
+ for header in $(find ${S}/packages/ -name "*.h") ; do
+ install -d ${STAGING_INCDIR}/codec-engine/$(dirname $header | sed s:${S}::g)
+ cp -pPr $header ${STAGING_INCDIR}/codec-engine/$(echo $header | sed s:${S}::g)
+ done
+
+}
+
+pkg_postinst_${PN}-module () {
+ if [ -n "$D" ]; then
+ exit 1
+ fi
+ depmod -a
+ update-modules || true
+}
+
+pkg_postrm_${PN}-module () {
+ update-modules || true
+}
+
+PACKAGES =+ "dsplink-cmemk-module"
+FILES_dsplink-cmemk-module = "${sysconfdir} /lib/modules/${KERNEL_VERSION}/kernel/drivers/dsp/*ko"
+INHIBIT_PACKAGE_STRIP = "1"
+
+FILES_${PN} = "${base_sbindir}"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
diff --git a/packages/dsplink/dsplink.inc b/packages/dsplink/dsplink.inc
index 780ea43d12..3b18d490cd 100644
--- a/packages/dsplink/dsplink.inc
+++ b/packages/dsplink/dsplink.inc
@@ -113,8 +113,8 @@ do_install () {
do_stage() {
- install -d ${STAGING_LIBDIR}
- install -m 0755 ${S}/gpp/BUILD/EXPORT/RELEASE/dsplink.lib ${STAGING_LIBDIR}/
+ install -d ${STAGING_DIR_TARGET}/dsplink
+ cp -pPr ${S}/* ${STAGING_DIR_TARGET}/dsplink/
}
pkg_postinst_${PN}-module () {
diff --git a/packages/dsplink/ti-paths.inc b/packages/dsplink/ti-paths.inc
index 3657d54527..b54f4bc6f5 100644
--- a/packages/dsplink/ti-paths.inc
+++ b/packages/dsplink/ti-paths.inc
@@ -2,7 +2,7 @@
TITOOLSDIR ?= "/OE/TI"
# Path under TITOOLSDIR where dspbios is unpacked
TIBIOSDIR ?= "bios_5_32_04"
-TIXDCTOOLSDIR ?= "${TIBIOSDIR}/xdctools"
+TIXDCTOOLSDIR ?= "${TITOOLSDIR}/xdctools_3_10_02"
# Path under TITOOLSDIR where the dsp toolchain is unpacked
TICGTOOLSDIR ?= "cg6x_6_0_19"