summaryrefslogtreecommitdiff
path: root/source/l/libvpx/libvpx.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'source/l/libvpx/libvpx.SlackBuild')
-rwxr-xr-xsource/l/libvpx/libvpx.SlackBuild30
1 files changed, 20 insertions, 10 deletions
diff --git a/source/l/libvpx/libvpx.SlackBuild b/source/l/libvpx/libvpx.SlackBuild
index e0c8c101..fc9608ef 100755
--- a/source/l/libvpx/libvpx.SlackBuild
+++ b/source/l/libvpx/libvpx.SlackBuild
@@ -1,9 +1,9 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for libvpx
# Copyright 2013 Matteo Bernardini <ponce@slackbuilds.org>, Pisa, Italy
-# Copyright 2014 Patrick J. Volkerding, Sebeka, MN, USA
+# Copyright 2014, 2018 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -23,9 +23,11 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+cd $(dirname $0) ; CWD=$(pwd)
+
PKGNAM=libvpx
-VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z* | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
-BUILD=${BUILD:-1}
+VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
+BUILD=${BUILD:-2}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -35,6 +37,14 @@ 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 "$PKGNAM-$VERSION-$ARCH-$BUILD.txz"
+ exit 0
+fi
+
NUMJOBS=${NUMJOBS:--j6}
if [ "$ARCH" = "i586" ]; then
@@ -55,7 +65,6 @@ else
ARCHOPTS="--target=${ARCH}-linux-gcc"
fi
-CWD=$(pwd)
TMP=${TMP:-/tmp}
PKG=$TMP/package-$PKGNAM
@@ -63,7 +72,7 @@ rm -rf $PKG
mkdir -p $TMP $PKG
cd $TMP
rm -rf $PKGNAM-$VERSION
-tar xvf $CWD/$PKGNAM-$VERSION.tar.?z* || exit 1
+tar xvf $CWD/$PKGNAM-$VERSION.tar.?z || exit 1
cd $PKGNAM-$VERSION || exit 1
chown -R root:root .
find -L . \
@@ -82,9 +91,13 @@ cd build-tmp
--libdir=/usr/lib${LIBDIRSUFFIX} \
--disable-debug-libs \
--disable-debug \
- --enable-postproc \
--enable-vp8 \
+ --enable-postproc \
+ --enable-vp9 \
+ --enable-vp9-postproc \
+ --enable-vp9-highbitdepth \
--enable-shared \
+ --disable-static \
--enable-runtime-cpu-detect \
$ARCHOPTS
@@ -92,9 +105,6 @@ cd build-tmp
make install DESTDIR=$PKG || exit 1
cd ..
-# remove the static version
-rm $PKG/usr/lib${LIBDIRSUFFIX}/$PKGNAM.a
-
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