diff options
author | Joeny Ang | 2015-07-01 15:12:01 +0800 |
---|---|---|
committer | Joeny Ang | 2015-07-01 15:12:01 +0800 |
commit | 10dd46fd5c005e5855e9c59dda833b103a75b842 (patch) | |
tree | d79f10e970eb3fdc6807e0d8cde2e2abfdb1f390 | |
download | aur-10dd46fd5c005e5855e9c59dda833b103a75b842.tar.gz |
Initial import
-rw-r--r-- | .SRCINFO | 45 | ||||
-rw-r--r-- | LICENSE | 20 | ||||
-rw-r--r-- | PKGBUILD | 84 | ||||
-rw-r--r-- | air-video-server-enabled.autostart | 10 | ||||
-rw-r--r-- | air-video-server-systemd.service | 10 | ||||
-rw-r--r-- | air-video-server.autostart | 10 | ||||
-rw-r--r-- | air-video-server.install | 66 | ||||
-rw-r--r-- | air-video-server.properties | 7 | ||||
-rw-r--r-- | air-video-server.rc | 52 | ||||
-rw-r--r-- | air-video-server.service | 13 | ||||
-rw-r--r-- | air-video-server.sh | 27 | ||||
-rw-r--r-- | mp4creator.sh | 8 |
12 files changed, 352 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..0a351efd2228 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,45 @@ +pkgbase = air-video-server + pkgdesc = A media server that can stream videos in almost any format from your PC to your iPhone, iPad and iPod touch + pkgver = 2.4.6_beta3 + pkgrel = 8 + url = http://www.inmethod.com/air-video/index.html + install = air-video-server.install + arch = i686 + arch = x86_64 + license = custom + makedepends = yasm + depends = zlib + depends = lame + depends = x264 + depends = faac + depends = gpac + depends = java-runtime + depends = fontconfig + depends = libcups + noextract = AirVideoServerLinux.jar + backup = etc/conf.d/air-video-server + source = http://s3.amazonaws.com/AirVideo/Linux-2.4.6-beta3/libav.tar.bz2 + source = http://s3.amazonaws.com/AirVideo/Linux-2.4.6-beta3/AirVideoServerLinux.jar + source = air-video-server.properties + source = air-video-server.sh + source = air-video-server.rc + source = air-video-server.autostart + source = air-video-server-enabled.autostart + source = air-video-server.service + source = air-video-server-systemd.service + source = mp4creator.sh + source = LICENSE + md5sums = 2bb3080b08ad315c5372678866e4736c + md5sums = 76b74c9e7073e9d02916d82b485a2eef + md5sums = 3d5f5f3405cc867623a00023fc70f217 + md5sums = e5237f30a6db31e0f558ae2d95745071 + md5sums = d58ec49b2f158e3f15c4997cc830ad8c + md5sums = 702f82c153faf742ab451bf2f26500ea + md5sums = 8c22ac2bca52463ea2f2da3546d0e1cf + md5sums = e099a2317c599d99d75a9af2f8ba6fd0 + md5sums = 572cd90983febcf97b7ce5633240db95 + md5sums = 6e9403f1dd14654844ece68a3cc35f7e + md5sums = 44dd1b2e8cf08cb372ba51217d267ad5 + +pkgname = air-video-server + diff --git a/LICENSE b/LICENSE new file mode 100644 index 000000000000..055dd2efe82d --- /dev/null +++ b/LICENSE @@ -0,0 +1,20 @@ +Matej Knopp +Copyright © 2009 InMethod s.r.o. +http://www.inmethod.com/ + +From: http://www.inmethod.com/air-video/licenses.html + +Air Video is distributed with a custom build of FFMpeg software. +FFMpeg is licensed under LGPL and GPL licenses. +FFMpeg is linked with libX264 (GPL) and libfaac (LGPL). + +FFmpeg source code used in Air Video Server 2.4.5-beta3 and newer +can be downloaded here: +http://www.inmethod.com/air-video/download/ffmpeg-for-2.4.5.tar.bz2 + +The original AirVideoServerLinux.jar and test.properties can be +downloaded from this forum posting: +http://www.inmethod.com/forum/posts/list/60/34.page#3935 + +Latest AVS Linux download links and information can be found here: +http://www.inmethod.com/forum/posts/list/1856.page diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..18ce0a2f7f9a --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,84 @@ +# Contributor: Joeny Ang <ang(dot)joeny(at)gmail(dot)com> +# Contributor: Lukas Nagl <LukasN(at)gmx(dot)at> +# Contributor: DocterD <docterdee(at)gmail(dot)com> +# Contributor: benwbooth <benwbooth(at)gmail(dot)com> +# Contributor: Antoine Martin <antoine(dot)a(dot)martin(at)gmail(dot)com> +# Contributor: Michie DeBerry <michie(dot)deberry(at)gmail(dot)com> +# Contributor: Jorge Israel Peña <jorgepblank(at)gmail(dot)com> + +pkgname=air-video-server +pkgver=2.4.6_beta3 +_pkgver=2.4.6-beta3 +pkgrel=8 +pkgdesc="A media server that can stream videos in almost any format from your PC to your iPhone, iPad and iPod touch" +arch=('i686' 'x86_64') +url="http://www.inmethod.com/air-video/index.html" +license=('custom') +depends=('zlib' 'lame' 'x264' 'faac' 'gpac' 'java-runtime' 'fontconfig' 'libcups') +makedepends=('yasm') +backup=('etc/conf.d/air-video-server') +install=${pkgname}.install +source=(http://s3.amazonaws.com/AirVideo/Linux-${_pkgver}/libav.tar.bz2 + http://s3.amazonaws.com/AirVideo/Linux-${_pkgver}/AirVideoServerLinux.jar + ${pkgname}.properties + ${pkgname}.sh + ${pkgname}.rc + ${pkgname}.autostart + ${pkgname}-enabled.autostart + ${pkgname}.service + ${pkgname}-systemd.service + mp4creator.sh + LICENSE) +noextract=('AirVideoServerLinux.jar') +md5sums=('2bb3080b08ad315c5372678866e4736c' + '76b74c9e7073e9d02916d82b485a2eef' + '3d5f5f3405cc867623a00023fc70f217' + 'e5237f30a6db31e0f558ae2d95745071' + 'd58ec49b2f158e3f15c4997cc830ad8c' + '702f82c153faf742ab451bf2f26500ea' + '8c22ac2bca52463ea2f2da3546d0e1cf' + 'e099a2317c599d99d75a9af2f8ba6fd0' + '572cd90983febcf97b7ce5633240db95' + '6e9403f1dd14654844ece68a3cc35f7e' + '44dd1b2e8cf08cb372ba51217d267ad5') + +build() { + cd ${srcdir}/libav + + TMPDIR=${srcdir} ./configure --prefix=/usr --enable-pthreads \ + --disable-shared --enable-static --enable-libfaac --enable-libx264 \ + --enable-libmp3lame --enable-gpl --enable-nonfree + make +} + +package() { + cd ${srcdir} + + # core files + install -m755 -d ${pkgdir}/usr/share/${pkgname} + install -m644 AirVideoServerLinux.jar ${pkgdir}/usr/share/${pkgname} + install -m644 ${pkgname}.properties ${pkgdir}/usr/share/${pkgname} + install -m755 libav/avconv ${pkgdir}/usr/share/${pkgname} + install -Dm755 mp4creator.sh ${pkgdir}/usr/share/${pkgname}/mp4creator + install -Dm755 ${pkgname}.sh ${pkgdir}/usr/bin/${pkgname} + install -Dm644 ${pkgname}.properties ${pkgdir}/etc/conf.d/${pkgname} + + # rc.d + install -Dm755 ${pkgname}.rc ${pkgdir}/etc/rc.d/${pkgname} + + # autostart + install -Dm644 ${pkgname}.autostart ${pkgdir}/etc/xdg/autostart/${pkgname}.desktop + install -m644 ${pkgname}-enabled.autostart ${pkgdir}/usr/share/${pkgname}/${pkgname}.desktop + + # avahi + install -Dm644 ${pkgname}.service ${pkgdir}/etc/avahi/services/${pkgname}.service + + # systemd + install -Dm644 ${pkgname}-systemd.service ${pkgdir}/usr/lib/systemd/system/${pkgname}.service + + # licenses + install -m755 -d ${pkgdir}/usr/share/licenses/${pkgname} + install -m644 LICENSE ${pkgdir}/usr/share/licenses/${pkgname}/ + install -m755 -d ${pkgdir}/usr/share/licenses/${pkgname}/libav + install -m644 libav/{LICENSE,COPYING.*} ${pkgdir}/usr/share/licenses/${pkgname}/libav +} diff --git a/air-video-server-enabled.autostart b/air-video-server-enabled.autostart new file mode 100644 index 000000000000..86a3c8bcc665 --- /dev/null +++ b/air-video-server-enabled.autostart @@ -0,0 +1,10 @@ +[Desktop Entry] +Encoding=UTF-8 +Name=Air Video Server +Icon= +Comment= +Exec=/usr/bin/air-video-server +Terminal=false +Type=Application +Categories= +X-GNOME-Autostart-enabled=true diff --git a/air-video-server-systemd.service b/air-video-server-systemd.service new file mode 100644 index 000000000000..fa2a1ff903fa --- /dev/null +++ b/air-video-server-systemd.service @@ -0,0 +1,10 @@ +[Unit] +Description=Air Video Server +After=network.target + +[Service] +PIDFile=/var/run/air-video-server.pid +ExecStart=/usr/bin/air-video-server + +[Install] +WantedBy=multi-user.target diff --git a/air-video-server.autostart b/air-video-server.autostart new file mode 100644 index 000000000000..8895678b7b68 --- /dev/null +++ b/air-video-server.autostart @@ -0,0 +1,10 @@ +[Desktop Entry] +Encoding=UTF-8 +Name=Air Video Server +Icon= +Comment= +Exec=/usr/bin/air-video-server +Terminal=false +Type=Application +Categories= +X-GNOME-Autostart-enabled=false diff --git a/air-video-server.install b/air-video-server.install new file mode 100644 index 000000000000..6a318ab9f43f --- /dev/null +++ b/air-video-server.install @@ -0,0 +1,66 @@ +post_install() { + cat << END_OF_MESSAGE +--------------------------- +Necessary additional setup: +--------------------------- +1. To manually start the server: + +Copy /usr/share/air-video-server/air-video-server.properties to +~/.air-video-server/air-video-server.properties and add your +video folders (see Properties file section below). + +Then run "air-video-server" from the command line. + +2. To autostart the server upon logging into your GNOME account: + +GNOME 2.x: +To start the server every time you logon to your GNOME account, go to +Preferences -> Startup Applications -> Startup Programs tab and enable +Air Video Server. + +GNOME 3.0 to 3.10: +Run "gnome-session-properties" from the command line, go to Startup Programs +tab and enable Air Video Server. + +GNOME 3.12 up: +Copy /usr/share/air-video-server/air-video-server.desktop to +~/.config/autostart folder. + +3. To autostart the server as a daemon upon bootup (requires 'root' access): + +initscripts: +Add air-video-server to your /etc/rc.conf DAEMONS=() line. + +systemd: +run "systemctl enable air-video-server.service" from the command line. + +The properties will be read from /etc/conf.d/air-video-server. + +--------------- +Properties file +--------------- +The folders format is: <label1>:<path1>,<label2>:<path2>,…,<labelN>:<pathN> +Leave the other options as they are. + +END_OF_MESSAGE +} + +post_upgrade() { + cat << UPGRADE_MESSAGE +------------------------------ +Important Upgrade Information: +------------------------------ +If the Air Video client app shows that certain media files are 'invalid', +your thumbnail cache has been corrupted due to a dependency package +version incompatibility. + +The solution is to clear out the thumbnail cache. Run the following at +the command line: + +rm -rv ~/.air-video-server + +Note: You will need to login as 'root' and run the above command if the +server is started as a daemon. + +UPGRADE_MESSAGE +} diff --git a/air-video-server.properties b/air-video-server.properties new file mode 100644 index 000000000000..8c4cbbff150d --- /dev/null +++ b/air-video-server.properties @@ -0,0 +1,7 @@ +path.ffmpeg = /usr/share/air-video-server/avconv +path.mp4creator = /usr/share/air-video-server/mp4creator +path.faac = /usr/bin/faac +password = +subtitles.encoding = windows-1250 +subtitles.font = Verdana +folders = Movies:/Volumes/Data/Movies,Series:/Volumes/Data/Series diff --git a/air-video-server.rc b/air-video-server.rc new file mode 100644 index 000000000000..7b62e2eb9f18 --- /dev/null +++ b/air-video-server.rc @@ -0,0 +1,52 @@ +#!/bin/bash + +. /etc/rc.conf +. /etc/rc.d/functions + +NAME=air-video-server +PIDFILE=/var/run/$NAME.pid +PROPFILE=/etc/conf.d/$NAME + +case "$1" in + start) + stat_busy "Starting Air Video Server" + if [ -a $PIDFILE ]; then + echo "Server already started." + stat_fail + else + /usr/bin/$NAME $PROPFILE & + if [ $? -gt 0 ]; then + stat_fail + else + add_daemon $NAME + echo $! > $PIDFILE + stat_done + fi + fi + ;; + stop) + stat_busy "Stopping Air Video Server" + if [ -a $PIDFILE ]; then + PID=`cat $PIDFILE` + kill $PID > /dev/null + if [ $? -gt 0 ]; then + stat_fail + else + rm $PIDFILE + rm_daemon $NAME + stat_done + fi + else + echo "Server not started." + stat_fail + fi + ;; + restart) + $0 stop + sleep 2 + $0 start + ;; + *) + echo "usage: $0 {start|stop|restart}" +esac +exit 0 diff --git a/air-video-server.service b/air-video-server.service new file mode 100644 index 000000000000..0b352bd0a541 --- /dev/null +++ b/air-video-server.service @@ -0,0 +1,13 @@ +<?xml version="1.0" standalone='no'?><!--*-nxml-*--> +<!DOCTYPE service-group SYSTEM "avahi-service.dtd"> + +<!-- This file is part of air-video-server --> + +<service-group> + <name replace-wildcards="yes">%h</name> + + <service> + <type>_airvideoserver._tcp</type> + <port>45631</port> + </service> +</service-group> diff --git a/air-video-server.sh b/air-video-server.sh new file mode 100644 index 000000000000..617550616266 --- /dev/null +++ b/air-video-server.sh @@ -0,0 +1,27 @@ +#!/bin/sh + +[ -x /etc/profile.d/openjdk6.sh ] && . /etc/profile.d/openjdk6.sh +[ -x /etc/profile.d/jdk.sh ] && . /etc/profile.d/jdk.sh +[ -x /etc/profile.d/jre.sh ] && . /etc/profile.d/jre.sh + +PROPFILE='/etc/conf.d/air-video-server' +LOCALPROP=`echo ~/.air-video-server/air-video-server.properties` + +([ "$1" = "verbose" ] || [ "$2" = "verbose" ]) && VERBOSE="1" +if [ -a "$1" ]; then + PROPFILE="$1" +else + if [ -a "$2" ]; then + PROPFILE="$2" + else + [ -a $LOCALPROP ] && PROPFILE=$LOCALPROP + fi +fi + +EXECLINE="$JAVA_HOME/bin/java -Djava.awt.headless=true -jar /usr/share/air-video-server/AirVideoServerLinux.jar "$PROPFILE"" +if [ -n "$VERBOSE" ]; then + exec $EXECLINE +else + exec $EXECLINE > /dev/null 2> /dev/null +fi + diff --git a/mp4creator.sh b/mp4creator.sh new file mode 100644 index 000000000000..cc9b76f1aaba --- /dev/null +++ b/mp4creator.sh @@ -0,0 +1,8 @@ +#!/bin/sh + +if [ "$#" -gt 5 ]; then + MP4Box -fps "$4" -add "$2" "$6" +else + MP4Box -add "$2" "$3" +fi + |