aboutsummaryrefslogtreecommitdiff
path: root/multimedia/mlt/mlt.SlackBuild
diff options
context:
space:
mode:
authorEdward W. Koenig <kingbeowulf@gmail.com>2016-10-29 05:54:05 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2016-10-29 05:54:05 +0700
commita22919819fb62e3c01efb5cde1f0df49d6e6f182 (patch)
tree067612ee7d48184ff7e57645a1145be55570ac8e /multimedia/mlt/mlt.SlackBuild
parent6495237d5ccb8a7e9861789a987723b1cfeccb48 (diff)
multimedia/mlt: added optional qt5 support, various fixes.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'multimedia/mlt/mlt.SlackBuild')
-rw-r--r--multimedia/mlt/mlt.SlackBuild30
1 files changed, 23 insertions, 7 deletions
diff --git a/multimedia/mlt/mlt.SlackBuild b/multimedia/mlt/mlt.SlackBuild
index 45859d033c55c..4d6a3de0b892d 100644
--- a/multimedia/mlt/mlt.SlackBuild
+++ b/multimedia/mlt/mlt.SlackBuild
@@ -47,10 +47,11 @@
# +---------------------------------------+
# 20-MAR-2016 new maintainer, version update to 6.0.0
# 11-OCT-2016 version update
+# 22-OCT-2016 add qt5 support, bug fixes/addenda (Larry Hajali)
PRGNAM=mlt
VERSION=${VERSION:-6.2.0}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@@ -75,11 +76,19 @@ if [ -f "$(which php)" ]; then php="php"; else php=""; fi
if [ -f "$(which python)" ]; then python="python"; else python=""; fi
if [ -h "$(which tclsh)" ]; then tcl="tcl"; else tcl=""; fi
if [ -f "$(which csharp)" ]; then csharp="csharp"; else csharp=""; fi
-# missing mlt.h in mlt-6.0.0/src/swig/ruby; broken src
-ruby="" #if [ -f "$(which ruby)" ]; then ruby="ruby"; else ruby=""; fi
+if [ -f "$(which ruby)" ]; then ruby="ruby"; else ruby=""; fi
if pkg-config --exists vdpau ; then vdpau="--avformat-vdpau" ; else vdpau="" ; fi
+# Use qt5 if present, otherwise system default
+if pkg-config --exists Qt5 ; then
+ qt="--qt-libdir=$(pkg-config Qt5 --variable=libdir)
+ --qt-includedir=$(pkg-config Qt5 --variable=headerdir)"
+else
+ qt="--qt-libdir=$(pkg-config Qt --variable=libdir)
+ --qt-includedir=$(pkg-config Qt --variable=headerdir)"
+fi
+
if [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
@@ -115,12 +124,12 @@ CXXFLAGS="$SLKCFLAGS" \
--disable-debug \
--prefix=/usr \
--libdir=/usr/lib${LIBDIRSUFFIX} \
- --qimage-libdir=${QT4DIR}/qt/lib \
- --qimage-includedir=${QT4DIR}/qt/include \
--enable-gpl \
+ --enable-gpl3 \
--luma-compress \
--enable-motion-est \
$vdpau \
+ $qt \
--swig-languages="$java $lua $perl $php $python $ruby $tcl $csharp" \
--build=$ARCH-slackware-linux
@@ -149,7 +158,13 @@ if [ "$php" ]; then
( cd $TMP/$PRGNAM-$VERSION/src/swig/php
install -D -m 0755 mlt.so $PKG/usr/lib$LIBDIRSUFFIX/php/extensions/mlt.so
install -D -m 0644 play.php $PKG/usr/doc/$PRGNAM-$VERSION/play.php
+ mkdir -p $PKG/etc/php.d
+ cat > $PKG/etc/php.d/$PRGNAM.ini.new << EOF
+; Enable mlt extension module
+; extension=$PRGNAM.so
+EOF
)
+ echo "config etc/php.d/$PRGNAM.ini.new" >> $CWD/doinst.sh
fi
if [ "$python" ]; then
PYTHONSITEPKG=$(python -c "import sys, os; print os.path.join('/usr/lib${LIBDIRSUFFIX}', 'python%s' % sys.version[:3], 'site-packages')")
@@ -175,14 +190,15 @@ if [ "$tcl" ]; then
install -D -m 0755 play.tcl $PKG/usr/doc/$PRGNAM-$VERSION/play.tcl
)
fi
+
# todo: java, csharp
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
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp AUTHORS ChangeLog NEWS COPYING README GPL \
-$PKG/usr/doc/$PRGNAM-$VERSION
+cp -a AUTHORS ChangeLog NEWS COPYING README GPL $PKG/usr/doc/$PRGNAM-$VERSION
+cat src/modules/motion_est/README > $PKG/usr/doc/$PRGNAM-$VERSION/README.motion_est
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install