Browse Source

multimedia/pocketsphinx: Updated for version 20230516_8221706.

Signed-off-by: Andrew Clemons <andrew.clemons@gmail.com>

Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
pull/206/head
Vijay Marcel 2 years ago
committed by Willy Sudiarto Raharjo
parent
commit
9999cf8123
No known key found for this signature in database GPG Key ID: 3F617144D7238786
  1. 17
      multimedia/pocketsphinx/changelog
  2. 40
      multimedia/pocketsphinx/pocketsphinx.SlackBuild
  3. 8
      multimedia/pocketsphinx/pocketsphinx.info

17
multimedia/pocketsphinx/changelog

@ -0,0 +1,17 @@
Changelog for pocketsphinx SlackBuild Script
--------------------------------------------------------------------
03/09/2022:
Added to SBo
14/07/2023:
Updated to github commit id 8221706.
This version joins Opencv4 and lensfun
in not compiling with FFmpeg. FFmpeg will
detect pocketsphinx but it will eventually
run into error during compilation.This
seems to be FFmpeg upstream problem so
don't enable pocketsphinx in FFmpeg when
you try to recompile it.

40
multimedia/pocketsphinx/pocketsphinx.SlackBuild

@ -24,8 +24,8 @@
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=pocketsphinx
VERSION=${VERSION:-20220908_5a1370c}
COMMIT=${COMMIT:-5a1370c3e9333550caf74be2d292f8c0c2ad8778}
VERSION=${VERSION:-20230516_8221706}
COMMIT=${COMMIT:-82217064bf9abbfe021bc107829701934afdb248}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@ -38,33 +38,32 @@ if [ -z "$ARCH" ]; then
esac
fi
# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
# the name of the created package would be, and then exit. This information
# could be useful to other scripts.
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
exit 0
fi
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
if [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
SLKCFLAGS="-O2 -march=i586 -mtune=i686 -pipe -fPIC"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
SLKCFLAGS="-O2 -march=i686 -mtune=i686 -pipe -fPIC"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2"
SLKCFLAGS="-O2 -fPIC -march=x86-64 -mtune=native -pipe"
LIBDIRSUFFIX="64"
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""
fi
# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
# the name of the created package would be, and then exit. This information
# could be useful to other scripts.
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
exit 0
fi
set -e
trap 'echo "$0 FAILED at line $LINENO!" | tee -a $OUTPUT/error-${PRGNAM}.log' ERR
@ -83,10 +82,6 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
cmake -B build -S $TMP/$PRGNAM-$COMMIT \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
@ -99,13 +94,13 @@ cmake -B build -S $TMP/$PRGNAM-$COMMIT \
-DBUILD_SHARED_LIBS:BOOL=ON \
-DCMAKE_INSTALL_MANDIR=/usr/man
python3 setup.py build
cmake --build build
DESTDIR=$PKG cmake --install build
python3 setup.py install --root="${PKG}/" --optimize=1 --skip-build
python3 setup.py install --prefix=/usr --root=$PKG --optimize=1
cp "$PKG"/usr/include/pocketsphinx.h $PKG/usr/include/pocketsphinx
cp build/include/sphinxbase/sphinx_config.h "$PKG"/usr/include/sphinxbase
mkdir -pv $PKG/usr/include/sphinxbase
cp $PKG/usr/include/pocketsphinx.h $PKG/usr/include/pocketsphinx
cp build/include/pocketsphinx/sphinx_config.h $PKG/usr/include/sphinxbase
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
@ -119,6 +114,7 @@ rm -f $PKG/{,usr/}lib${LIBDIRSUFFIX}/*.la
mkdir -pv $PKG/usr/doc/$PRGNAM-$VERSION
cp -a AUTHORS NEWS LICENSE README.md $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
find $PKG/usr/doc/$PRGNAM-$VERSION -type f -exec chmod 0644 {} \+
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc

8
multimedia/pocketsphinx/pocketsphinx.info

@ -1,10 +1,10 @@
PRGNAM="pocketsphinx"
VERSION="20220908_5a1370c"
VERSION="20230516_8221706"
HOMEPAGE="https://github.com/cmusphinx/pocketsphinx"
DOWNLOAD="https://github.com/cmusphinx/pocketsphinx/archive/5a1370c/pocketsphinx-5a1370c3e9333550caf74be2d292f8c0c2ad8778.tar.gz"
MD5SUM="f39566488fbc1ea5650bc550fe320638"
DOWNLOAD="https://github.com/cmusphinx/pocketsphinx/archive/8221706/pocketsphinx-82217064bf9abbfe021bc107829701934afdb248.tar.gz"
MD5SUM="cfb2a548e1155a369a42cdfd12042430"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="scikit-build pytest python3-pytest python3-wheel sounddevice memory-profiler"
REQUIRES="scikit-build python3-pytest python3-wheel sounddevice memory-profiler"
MAINTAINER="Vijay Marcel"
EMAIL="vijaymarcel@outlook.com"
Loading…
Cancel
Save