Merge pull request #251 from KristofRobot/ros-pocketsphinx

pocketsphinx - initial commit
This commit is contained in:
Lukas Bulwahn 2014-04-20 21:37:17 +02:00
commit 055fb3b53f
5 changed files with 105 additions and 0 deletions

View File

@ -0,0 +1,9 @@
SRC_URI = "http://sourceforge.net/projects/cmusphinx/files/${PN}/${PV}/${P}.tar.gz;downloadfilename=${P}.tar.gz"
inherit autotools pythonnative python-dir
# required for python binding
export HOST_SYS
export BUILD_SYS
export STAGING_LIBDIR
export STAGING_INCDIR

View File

@ -0,0 +1,30 @@
DESCRIPTION = "This is PocketSphinx, one of Carnegie Mellon University's open source \
large vocabulary, speaker-independent continuous speech recognition engine."
LICENSE = "BSD"
LIC_FILES_CHKSUM = "file://COPYING;md5=6601be289d6bcad899b6e71623ce2862"
DEPENDS = "sphinxbase gst-plugins-good"
SRC_URI[md5sum] = "9f6fb6277d57fb33d2c49d4184587d26"
SRC_URI[sha256sum] = "874c4c083d91c8ff26a2aec250b689e537912ff728923c141c4dac48662cce7a"
require cmusphinx.inc
do_configure_prepend () {
#force build of gstreamer plugin
sed -i 's:AM_CONDITIONAL(BUILD_GST, test x$cross_compiling != xyes && test "x$HAVE_GST" = "xyes"):AM_CONDITIONAL(BUILD_GST, test "x$HAVE_GST" = "xyes"):g' ${S}/configure.in
}
do_install_append () {
#remove egg-info
rm -rf ${D}/${PYTHON_SITEPACKAGES_DIR}/*.egg-info
}
FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}/pocketsphinx.so"
FILES_${PN}-dbg += "${PYTHON_SITEPACKAGES_DIR}/.debug/*"
PACKAGES += "gstreamer0.10-${PN} gstreamer0.10-${PN}-dbg gstreamer0.10-${PN}-staticdev"
FILES_gstreamer0.10-${PN} += "${libdir}/gstreamer-0.10/libgstpocketsphinx.so"
FILES_gstreamer0.10-${PN}-staticdev += "${libdir}/gstreamer-0.10/libgstpocketsphinx.a \
${libdir}/gstreamer-0.10/libgstpocketsphinx.la"
FILES_gstreamer0.10-${PN}-dbg += "${libdir}/gstreamer-0.10/.debug"

View File

@ -0,0 +1,16 @@
diff --git a/test/regression/Makefile.am b/test/regression/Makefile.am
index d13d2a7..3bdb18a 100644
--- a/test/regression/Makefile.am
+++ b/test/regression/Makefile.am
@@ -33,9 +33,9 @@ CLEANFILES = test*.err test*.out \
# Disable sphinx_fe tests for now if fixed-point due to imprecision
if FIXED_POINT
-TESTS = $(srcdir)/test-cepview.sh $(srcdir)/test-sphinx_pitch.sh
+TESTS = test-cepview.sh test-sphinx_pitch.sh
else
-TESTS = $(srcdir)/test-*.sh
+TESTS = test-*.sh
endif
EXTRA_DIST += $(TESTS)

View File

@ -0,0 +1,21 @@
DESCRIPTION = "This package contains the basic libraries shared by the CMU Sphinx \
trainer and all the Sphinx decoders (Sphinx-II, Sphinx-III, and \
PocketSphinx), as well as some common utilities for manipulating \
acoustic feature and audio files."
LICENSE = "BSD"
LIC_FILES_CHKSUM = "file://COPYING;md5=c550e8ca1106e5eeaf4e2b4cbf960fcf"
SRC_URI[md5sum] = "7335d233f7ad4ecc4b508aec7b5dc101"
SRC_URI[sha256sum] = "55708944872bab1015b8ae07b379bf463764f469163a8fd114cbb16c5e486ca8"
require cmusphinx.inc
SRC_URI += "file://0001-TESTS-srcdir-remove.patch"
do_install_append () {
#remove egg-info
rm -rf ${D}/${PYTHON_SITEPACKAGES_DIR}/*.egg-info
}
FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}/sphinxbase.so"
FILES_${PN}-dbg += "${PYTHON_SITEPACKAGES_DIR}/.debug/*"

View File

@ -0,0 +1,29 @@
DESCRIPTION = "This package is a simple wrapper around the pocketsphinx speech recognizer, \
using gstreamer and a Python-based interface."
SECTION = "devel"
LICENSE = "BSD"
LIC_FILES_CHKSUM = "file://package.xml;beginline=10;endline=10;md5=d566ef916e9dedc494f5f793a6690ba5"
SRC_URI = "https://github.com/mikeferguson/pocketsphinx/archive/${PV}.tar.gz;downloadfilename=${PN}.tar.gz"
SRC_URI[md5sum] = "814912c0fa4e28dee0e7abc2576f1ad2"
SRC_URI[sha256sum] = "79aed79079d1ca4ac470ea55a82c1de13473df29187b7e8ecec86969c253284a"
S = "${WORKDIR}/pocketsphinx-${PV}"
inherit catkin
do_configure_prepend () {
#rename pocketsphinx to ros_pocketsphinx, to avoid collision with original pocketsphinx
sed -i 's:project(pocketsphinx):project(${ROS_SPN}):g' ${S}/CMakeLists.txt
sed -i 's:<name>pocketsphinx</name>:<name>${ROS_SPN}</name>:g' ${S}/package.xml
sed -i "s:load_manifest('pocketsphinx'):load_manifest('${ROS_SPN}'):g" ${S}/nodes/*py
sed -i 's:pkg="pocketsphinx:pkg="${ROS_SPN}:g' ${S}/demo/*launch
sed -i 's:find pocketsphinx:find ${ROS_SPN}:g' ${S}/demo/*launch
}
RDEPENDS_${PN} = "std-srvs rospy gstreamer0.10-pocketsphinx"
#provides gconfaudiosrc, used to find name of microphone
RRECOMMENDS_${PN} += "gst-plugins-good-gconfelements"
ROS_SPN = "ros_pocketsphinx"