multimedia/avidemux: Fix build issue.

Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
John Vogel 2015-03-10 23:55:55 +07:00 committed by Willy Sudiarto Raharjo
parent 1c7c84dc98
commit 401df620d7
3 changed files with 80 additions and 49 deletions

View File

@ -3,4 +3,17 @@ encoding tasks. It supports many file types, including AVI, DVD compatible
MPEG files, MP4 and ASF, using a variety of codecs. Tasks can be automated
using projects, job queue and powerful scripting capabilities.
By default only the cli and qt4 interfaces are built. Upstream currently
does not support the gtk interface and while it may build, the gtk gui
crashes during startup. To enable (or disable) an interface, use the
WITH_CLI, WITH_QT4, and WITH_GTK variables as such:
WITH_CLI=NO sh ./avidemux.SlackBuild
or, if you use fakeroot:
fakeroot env WITH_GTK=YES sh ./avidemux.SlackBuild
though building the gtk is not recommended or supported.
Optional dependencies are aften, amrnb, and jack-audio-connection-kit.

View File

@ -26,7 +26,7 @@
PRGNAM=avidemux
VERSION=${VERSION:-2.6.8}
BUILD=${BUILD:-1}
BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
DOCS="AUTHORS License.txt COPYING scripts/automkv.py"
@ -73,6 +73,10 @@ 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 {} \;
WITH_CLI=${WITH_CLI:-YES}
WITH_QT4=${WITH_QT4:-YES}
WITH_GTK=${WITH_GTK:-NO}
mkdir -p build_core
cd build_core
cmake \
@ -81,10 +85,11 @@ cd build_core
-DCMAKE_INSTALL_PREFIX=/usr \
-DFAKEROOT="$PKG" \
../avidemux_core
make
make install DESTDIR=$PKG
make -j 1
make -j 1 install DESTDIR=$PKG
cd ..
if [ "x$WITH_QT4" = "xYES" ]; then
mkdir -p build_qt4
cd build_qt4
cmake \
@ -93,10 +98,12 @@ cd build_qt4
-DCMAKE_INSTALL_PREFIX=/usr \
-DFAKEROOT="$PKG" \
../avidemux/qt4
make
make install DESTDIR=$PKG
make -j 1
make -j 1 install DESTDIR=$PKG
cd ..
fi
if [ "x$WITH_GTK" = "xYES" ]; then
mkdir -p build_gtk
cd build_gtk
cmake \
@ -105,10 +112,12 @@ cd build_gtk
-DCMAKE_INSTALL_PREFIX=/usr \
-DFAKEROOT="$PKG" \
../avidemux/gtk
make
make install DESTDIR=$PKG
make -j 1
make -j 1 install DESTDIR=$PKG
cd ..
fi
if [ "x$WITH_CLI" = "xYES" ]; then
mkdir -p build_cli
cd build_cli
cmake \
@ -117,9 +126,10 @@ cd build_cli
-DCMAKE_INSTALL_PREFIX=/usr \
-DFAKEROOT="$PKG" \
../avidemux/cli
make
make install DESTDIR=$PKG
make -j 1
make -j 1 install DESTDIR=$PKG
cd ..
fi
mkdir -p build_plugins_common
cd build_plugins_common
@ -131,10 +141,11 @@ cd build_plugins_common
-DPLUGIN_UI=COMMON \
-DFAKEROOT="$PKG" \
../avidemux_plugins
make
make install DESTDIR=$PKG
make -j 1
make -j 1 install DESTDIR=$PKG
cd ..
if [ "x$WITH_QT4" = "xYES" ]; then
mkdir -p build_plugins_qt4
cd build_plugins_qt4
cmake \
@ -145,10 +156,12 @@ cd build_plugins_qt4
-DPLUGIN_UI=QT4 \
-DFAKEROOT="$PKG" \
../avidemux_plugins
make
make install DESTDIR=$PKG
make -j 1
make -j 1 install DESTDIR=$PKG
cd ..
fi
if [ "x$WITH_GTK" = "xYES" ]; then
mkdir -p build_plugins_gtk
cd build_plugins_gtk
cmake \
@ -159,10 +172,12 @@ cd build_plugins_gtk
-DPLUGIN_UI=GTK \
-DFAKEROOT="$PKG" \
../avidemux_plugins
make
make install DESTDIR=$PKG
make -j 1
make -j 1 install DESTDIR=$PKG
cd ..
fi
if [ "x$WITH_CLI" = "xYES" ]; then
mkdir -p build_plugins_cli
cd build_plugins_cli
cmake \
@ -173,15 +188,21 @@ cd build_plugins_cli
-DPLUGIN_UI=CLI \
-DFAKEROOT="$PKG" \
../avidemux_plugins
make
make install DESTDIR=$PKG
make -j 1
make -j 1 install DESTDIR=$PKG
cd ..
fi
mkdir -p $PKG/usr/share/applications
mkdir -p $PKG/usr/share/pixmaps
install -m644 avidemux2.desktop $PKG/usr/share/applications/avidemux2_gtk.desktop
cat avidemux2.desktop | sed -e 's/_gtk/_qt4/' \
> $PKG/usr/share/applications/avidemux2_qt4.desktop
if [ "x$WITH_QT4" = "xYES" ]; then
cat avidemux2.desktop | sed -e 's/avidemux2$/avidemux/' -e 's/2_gtk/3_qt/' >\
$PKG/usr/share/applications/avidemux_qt.desktop
fi
if [ "x$WITH_GTK" = "xYES" ]; then
cat avidemux2.desktop | sed -e 's/avidemux2$/avidemux/' -e 's/2_gtk/3_gtk/' >\
$PKG/usr/share/applications/avidemux_gtk.desktop
fi
install -m644 avidemux_icon.png $PKG/usr/share/pixmaps/avidemux.png
for sz in 16x16 32x32 48x48 64x64 ; do
mkdir -p $PKG/usr/share/icons/hicolor/$sz/apps
@ -190,14 +211,11 @@ for sz in 16x16 32x32 48x48 64x64 ; do
done
mkdir -p $PKG/usr/man/man1
install -m644 man/avidemux.1 $PKG/usr/man/man1/avidemux.1
gzip -c man/avidemux.1 > $PKG/usr/man/man1/avidemux.1.gz
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
find $PKG/usr/man -type f -exec gzip -9 {} \;
for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
mkdir -p $PKG/usr/doc/${PRGNAM}-${VERSION}
cp -a $DOCS $PKG/usr/doc/${PRGNAM}-${VERSION}
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/${PRGNAM}-${VERSION}/$PRGNAM.SlackBuild

View File

@ -7,4 +7,4 @@ DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="a52dec faac faad2 lame libdca x264 xvidcore"
MAINTAINER="John Vogel"
EMAIL="jvogel@stny.rr.com"
EMAIL="jvogel4@stny.rr.com"