summaryrefslogtreecommitdiffstats
path: root/multimedia/minitube/minitube.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'multimedia/minitube/minitube.SlackBuild')
-rw-r--r--multimedia/minitube/minitube.SlackBuild56
1 files changed, 31 insertions, 25 deletions
diff --git a/multimedia/minitube/minitube.SlackBuild b/multimedia/minitube/minitube.SlackBuild
index 83c33ca636..115089f486 100644
--- a/multimedia/minitube/minitube.SlackBuild
+++ b/multimedia/minitube/minitube.SlackBuild
@@ -1,8 +1,10 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for minitube
-# Copyright 2009 Mikhail Zotov < mikhail dot ru at gmail dot com >
+# Copyright 2009 Mikhail Zotov
+# Copyright 2021-2023 Johannes Schoepfer, Germany
+# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
@@ -21,38 +23,42 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-# Version number bumped by /dev/ammo42
+# 20220320 bkw: Modified by SlackBuilds.org: fix 32-bit build.
+
+cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=minitube
-VERSION=${VERSION:-2.1.3}
-BUILD=${BUILD:-1}
+VERSION=${VERSION:-3.9.3}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
- i?86) ARCH=i486 ;;
+ i?86) ARCH=i586 ;;
arm*) ARCH=arm ;;
*) ARCH=$( uname -m ) ;;
esac
fi
-CWD=$(pwd)
+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" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mtune=i686"
- LIBDIRSUFFIX=""
+# 20220320 bkw: we need -fPIC even for 32-bit.
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686 -fPIC"
elif [ "$ARCH" = "i686" ]; then
- SLKCFLAGS="-O2 -march=i686 -mtune=i686"
- LIBDIRSUFFIX=""
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686 -fPIC"
elif [ "$ARCH" = "x86_64" ]; then
- SLKCFLAGS="-O2 -fPIC -m64"
- LIBDIRSUFFIX="64"
+ SLKCFLAGS="-O2 -fPIC"
else
SLKCFLAGS="-O2"
- LIBDIRSUFFIX=""
fi
set -e
@@ -61,18 +67,18 @@ rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/$PRGNAM-$VERSION.tar.?z*
+tar xvf $CWD/$PRGNAM-$VERSION.tar.bz2
cd $PRGNAM-$VERSION
chown -R root:root .
find -L . \
- \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 -o -perm 511 \) \
- -exec chmod 755 {} \; -o \
- \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
- -exec chmod 644 {} \;
-
-# Fix building with gcc-4.7.x
-patch -p1 < $CWD/minitube-gcc47.patch
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} + -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} +
+# fix for mpv >= 0.35, thanks to Chris Willing
+sed -i -e '/mpv_opengl_init_params/ s/, nullptr};/};/' \
+ lib/media/src/mpv/mpvwidget.cpp
qmake
# Use our SLKCFLAGS plus the hardcoded ones from the Makefile
make \
@@ -82,7 +88,7 @@ make install INSTALL_ROOT=$PKG
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a \
- AUTHORS CHANGES COPYING INSTALL TODO \
+ AUTHORS CHANGES COPYING TODO \
$PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
@@ -91,4 +97,4 @@ cat $CWD/slack-desc > $PKG/install/slack-desc
cat $CWD/doinst.sh > $PKG/install/doinst.sh
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE