summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Willing <chris.willing@iinet.net.au>2014-09-06 01:58:16 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2014-09-06 01:58:16 +0700
commitc7c8866506dd6c57941b83d098c68055e8b1d756 (patch)
tree7ac54fb02e41293b28114be8b50c61ae872b4f14
parenteee86e8329d10433ccacf7c939bff2cc28f1d3b6 (diff)
downloadslackbuilds-c7c8866506dd6c57941b83d098c68055e8b1d756.tar.gz
multimedia/vlc: Added (VLC media player).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
-rw-r--r--multimedia/vlc/README19
-rw-r--r--multimedia/vlc/doinst.sh.in17
-rw-r--r--multimedia/vlc/patch-freerdp.diff76
-rw-r--r--multimedia/vlc/patch-projectM-fontpath.diff13
-rw-r--r--multimedia/vlc/slack-desc19
-rw-r--r--multimedia/vlc/vlc.SlackBuild138
-rw-r--r--multimedia/vlc/vlc.info12
7 files changed, 294 insertions, 0 deletions
diff --git a/multimedia/vlc/README b/multimedia/vlc/README
new file mode 100644
index 0000000000..30b6ce952d
--- /dev/null
+++ b/multimedia/vlc/README
@@ -0,0 +1,19 @@
+VLC media player is a free and open source media player and multi-
+media framework written by the VideoLAN project. VLC is a portable
+multimedia player, encoder, and streamer supporting many audio and
+video codecs and file formats as well as DVDs, VCDs, and various
+streaming protocols. It is able to stream over networks and to
+transcode multimedia files and save them into various formats.
+
+This build aims to support as many options as possible using
+the SlackBuilds listed in the REQUIRES field of the vlc.info file.
+No script changes are necessary to include particular options; if they
+are detected at at build time, they will be included. Conversely if
+optional packages are not available at build time, vlc will continue
+to build with a reduced feature set.
+
+This SlackBuild also builds in support for BlackMagic Design's "Decklink"
+range of video inout and output cards, including those with UHD (3840x2160)
+capability.
+
+Please advise the maintainer to suggest support for any further options.
diff --git a/multimedia/vlc/doinst.sh.in b/multimedia/vlc/doinst.sh.in
new file mode 100644
index 0000000000..03a4d01e28
--- /dev/null
+++ b/multimedia/vlc/doinst.sh.in
@@ -0,0 +1,17 @@
+if [ -x /usr/bin/update-desktop-database ]; then
+ /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
+fi
+
+if [ -x /usr/bin/update-mime-database ]; then
+ /usr/bin/update-mime-database usr/share/mime >/dev/null 2>&1
+fi
+
+if [ -e usr/share/icons/hicolor/icon-theme.cache ]; then
+ if [ -x /usr/bin/gtk-update-icon-cache ]; then
+ /usr/bin/gtk-update-icon-cache usr/share/icons/hicolor >/dev/null 2>&1
+ fi
+fi
+
+if [ ! -e usr/lib%LIBDIRSUFFIX%/vlc/plugins*.dat ] ; then
+ /usr/lib%LIBDIRSUFFIX%/vlc/vlc-cache-gen -f usr/lib%LIBDIRSUFFIX%/vlc
+fi
diff --git a/multimedia/vlc/patch-freerdp.diff b/multimedia/vlc/patch-freerdp.diff
new file mode 100644
index 0000000000..c1f4f23295
--- /dev/null
+++ b/multimedia/vlc/patch-freerdp.diff
@@ -0,0 +1,76 @@
+--- modules/access/rdp.c.orig 2013-06-24 18:00:38.000000000 +0000
++++ modules/access/rdp.c 2014-08-14 07:20:03.000000000 +0000
+@@ -41,6 +41,22 @@
+ #include <freerdp/channels/channels.h>
+ #include <freerdp/gdi/gdi.h>
+
++#if !defined(FREERDP_INTERFACE_VERSION)
++# include <freerdp/version.h>
++#endif
++
++#if !defined(FREERDP_VERSION_MAJOR) || \
++ (defined(FREERDP_VERSION_MAJOR) && !(FREERDP_VERSION_MAJOR >= 1 && FREERDP_VERSION_MINOR >= 1 ))
++# define SoftwareGdi sw_gdi
++# define Fullscreen fullscreen
++# define ServerHostname hostname
++# define Username username
++# define Password password
++# define ServerPort port
++# define EncryptionMethods encryption
++# define ContextSize context_size
++#endif
++
+ #include <errno.h>
+ #ifdef HAVE_POLL
+ # include <poll.h>
+@@ -198,15 +214,15 @@
+ demux_sys_t *p_sys = p_vlccontext->p_demux->p_sys;
+
+ /* Configure connexion */
+- p_instance->settings->sw_gdi = true; /* render in buffer */
+- p_instance->settings->fullscreen = true;
+- p_instance->settings->hostname = strdup( p_sys->psz_hostname );
+- p_instance->settings->username =
++ p_instance->settings->SoftwareGdi = true; /* render in buffer */
++ p_instance->settings->Fullscreen = true;
++ p_instance->settings->ServerHostname = strdup( p_sys->psz_hostname );
++ p_instance->settings->Username =
+ var_InheritString( p_vlccontext->p_demux, CFG_PREFIX "user" );
+- p_instance->settings->password =
++ p_instance->settings->Password =
+ var_InheritString( p_vlccontext->p_demux, CFG_PREFIX "password" );
+- p_instance->settings->port = p_sys->i_port;
+- p_instance->settings->encryption =
++ p_instance->settings->ServerPort = p_sys->i_port;
++ p_instance->settings->EncryptionMethods =
+ var_InheritBool( p_vlccontext->p_demux, CFG_PREFIX "encrypt" );
+
+ return true;
+@@ -217,9 +233,16 @@
+ vlcrdp_context_t * p_vlccontext = (vlcrdp_context_t *) p_instance->context;
+
+ msg_Dbg( p_vlccontext->p_demux, "connected to desktop %dx%d (%d bpp)",
++#if (FREERDP_VERSION_MAJOR >= 1 && FREERDP_VERSION_MINOR >= 1 )
++ p_instance->settings->DesktopWidth,
++ p_instance->settings->DesktopHeight,
++ p_instance->settings->ColorDepth
++#else
+ p_instance->settings->width,
+ p_instance->settings->height,
+- p_instance->settings->color_depth );
++ p_instance->settings->color_depth
++#endif
++ );
+
+ p_instance->update->DesktopResize = desktopResizeHandler;
+ p_instance->update->BeginPaint = beginPaintHandler;
+@@ -415,7 +438,7 @@
+ p_sys->p_instance->Authenticate = authenticateHandler;
+
+ /* Set up context handlers and let it be allocated */
+- p_sys->p_instance->context_size = sizeof( vlcrdp_context_t );
++ p_sys->p_instance->ContextSize = sizeof( vlcrdp_context_t );
+ freerdp_context_new( p_sys->p_instance );
+
+ vlcrdp_context_t * p_vlccontext = (vlcrdp_context_t *) p_sys->p_instance->context;
+diff -Nru vlc-2.1.5/modules/access/rtp/input.c vlc-2.2.0~pre2/modules/access/rtp/input.c
diff --git a/multimedia/vlc/patch-projectM-fontpath.diff b/multimedia/vlc/patch-projectM-fontpath.diff
new file mode 100644
index 0000000000..5c4726296c
--- /dev/null
+++ b/multimedia/vlc/patch-projectM-fontpath.diff
@@ -0,0 +1,13 @@
+--- modules/visualization/projectm.cpp.orig 2013-09-13 01:18:34.000000000 +1000
++++ modules/visualization/projectm.cpp 2014-09-04 14:53:21.510242036 +1000
+@@ -79,8 +79,8 @@
+ # define FONT_PATH_MENU "C:\\WINDOWS\\Fonts\\arial.ttf"
+ # define PRESET_PATH NULL
+ #else
+-# define FONT_PATH "/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans.ttf"
+-# define FONT_PATH_MENU "/usr/share/fonts/truetype/ttf-dejavu/DejaVuSansMono.ttf"
++# define FONT_PATH "/usr/share/fonts/TTF/DejaVuSans.ttf"
++# define FONT_PATH_MENU "/usr/share/fonts/TTF/DejaVuSansMono.ttf"
+ # define PRESET_PATH "/usr/share/projectM/presets"
+ #endif
+
diff --git a/multimedia/vlc/slack-desc b/multimedia/vlc/slack-desc
new file mode 100644
index 0000000000..4ff7f2d288
--- /dev/null
+++ b/multimedia/vlc/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description.
+# Line up the first '|' above the ':' following the base package name, and
+# the '|' on the right side marks the last column you can put a character in.
+# You must make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':' except on otherwise blank lines.
+
+ |-----handy-ruler------------------------------------------------------|
+vlc: vlc (VLC media player)
+vlc:
+vlc: VLC media player is a free and open source media player and multi-
+vlc: media framework written by the VideoLAN project. VLC is a portable
+vlc: multimedia player, encoder, and streamer supporting many audio and
+vlc: video codecs and file formats as well as DVDs, VCDs, and various
+vlc: streaming protocols. It is able to stream over networks and to
+vlc: transcode multimedia files and save them into various formats.
+vlc:
+vlc: homepage: http://www.videolan.org/vlc/
+vlc:
diff --git a/multimedia/vlc/vlc.SlackBuild b/multimedia/vlc/vlc.SlackBuild
new file mode 100644
index 0000000000..3d6c200593
--- /dev/null
+++ b/multimedia/vlc/vlc.SlackBuild
@@ -0,0 +1,138 @@
+#!/bin/sh
+
+# Slackware build script for VLC media player
+# Written by Andrea De Pasquale <andrea@de-pasquale.name>
+# Based on Eric Hameleers' Slackware build script,
+# modified to build VLC only, shared libraries needed.
+
+# Copyright (c) 2007,2008,2009,2010,2011 Eric Hameleers, Eindhoven, Netherlands
+# Copyright (c) 2014 Christoph Willing, Brisbane, Australia
+#
+# Permission to use, copy, modify, and distribute this software for
+# any purpose with or without fee is hereby granted, provided that
+# the above copyright notice and this permission notice appear in all
+# copies.
+#
+# THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
+# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
+# USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+# -----------------------------------------------------------------------------
+
+PRGNAM=vlc
+VERSION=${VERSION:-2.1.5}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i486 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+DECKLINK_SDK_VERSION=${DECKLINK_SDK_VERSION:-10.1.4}
+DECKLINKSDK=Blackmagic_DeckLink_SDK_${DECKLINK_SDK_VERSION}.zip
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+DOCS="ABOUT-NLS AUTHORS COPYING INSTALL NEWS README THANKS"
+
+# In an ordinary virtual machine, since a different kernal is running,
+# a unique dbus id is needed.
+# However with LXC, the same kernel is used in each container,
+# so we insert an arbitrary value
+#
+grep "CONTAINER=yes" /etc/rc.d/rc.S >/dev/null 2>/dev/null
+if [ $? -eq 0 ]; then
+ mkdir -p /var/lib/dbus/
+ echo "4349d719fcf875a557a8c00400000014" > /var/lib/dbus/machine-id
+fi
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.xz
+cd $PRGNAM-$VERSION
+
+mkdir -p decklink/include
+unzip -o $CWD/$DECKLINKSDK
+cp -p Blackmagic\ DeckLink\ SDK\ ${DECKLINK_SDK_VERSION}/Linux/include/* decklink/include/
+
+patch -p0 < $CWD/patch-freerdp.diff
+patch -p0 < $CWD/patch-projectM-fontpath.diff
+
+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 {} \;
+
+CFLAGS="$SLKCFLAGS" \
+CXXFLAGS="$SLKCFLAGS" \
+LDFLAGS="$SLKLDFLAGS" \
+./configure \
+ --prefix=/usr \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
+ --sysconfdir=/etc \
+ --mandir=/usr/man \
+ --docdir=/usr/doc/vlc-$VERSION \
+ --localstatedir=/var \
+ --build=$ARCH-slackware-linux \
+ --enable-merge-ffmpeg \
+ --with-kde-solid=no \
+ --with-decklink-sdk=$TMP/$PRGNAM-$VERSION/decklink
+
+make -j4
+make DESTDIR=$PKG install
+
+mkdir -p $PKG/usr/man/man1
+gzip -9c doc/vlc.1 > $PKG/usr/man/man1/vlc.1.gz
+
+mkdir -p $PKG/$(cd /usr/share/vim/vim*/syntax ; pwd)
+cp extras/analyser/vlc.vim $PKG/$(cd /usr/share/vim/vim*/syntax ; pwd)/
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION
+find $PKG/usr/doc -type f -exec chmod 644 {} \;
+chown -R root:root $PKG/usr/doc/$PRGNAM-$VERSION/*
+
+find $PKG/usr/man -type f -name "*.?" -exec gzip -9f {} \;
+for i in $(find $PKG/usr/man -type l -name "*.?") ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
+
+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
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+sed -e s/%LIBDIRSUFFIX%/$LIBDIRSUFFIX/g $CWD/doinst.sh.in > $PKG/install/doinst.sh
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
diff --git a/multimedia/vlc/vlc.info b/multimedia/vlc/vlc.info
new file mode 100644
index 0000000000..d5c11fb44c
--- /dev/null
+++ b/multimedia/vlc/vlc.info
@@ -0,0 +1,12 @@
+PRGNAM="vlc"
+VERSION="2.1.5"
+HOMEPAGE="http://www.videolan.org/vlc/"
+DOWNLOAD="http://download.videolan.org/pub/videolan/vlc/2.1.5/vlc-2.1.5.tar.xz \
+ http://software.blackmagicdesign.com/SDK/Blackmagic_DeckLink_SDK_10.1.4.zip"
+MD5SUM="3941b561f590cc95ca5e795213cba2f2 \
+ 16fbc2f49dc62fecac15835c538f78d4"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+REQUIRES="a52dec libass libdc1394 libdvbpsi libdvdnav libmpeg2 libupnp lua portaudio twolame opus libvpx gsm opencv libtar libkate faac libdca libmatroska libshout speex libva avahi projectM jack-audio-connection-kit libsidplay2 zvbi faad2 libavc1394 libmodplug musepack-tools vcdimager dirac vsxu gnome-vfs live555 rtmpdump freerdp libdvdcss fluidsynth schroedinger libminizip chromaprint"
+MAINTAINER="Christoph Willing"
+EMAIL="chris.willing@iinet.net.au"