diff options
author | Britney Fransen <brfransen@gmail.com> | 2016-03-16 12:58:08 (GMT) |
---|---|---|
committer | Britney Fransen <brfransen@gmail.com> | 2016-03-16 12:58:08 (GMT) |
commit | de3a21c0408251a1eea6f22bb5fbf2930e9c9d4e (patch) | |
tree | 15606aaf2b8a8e6ea4bbdd8b02e3ff415f9ec042 /abs/core/mythtv/stable-0.28/mythplugins | |
parent | fdf037dbc9eb74a71eec0ed5f7f30cb9b11434f1 (diff) | |
download | linhes_pkgbuild-de3a21c0408251a1eea6f22bb5fbf2930e9c9d4e.zip linhes_pkgbuild-de3a21c0408251a1eea6f22bb5fbf2930e9c9d4e.tar.gz linhes_pkgbuild-de3a21c0408251a1eea6f22bb5fbf2930e9c9d4e.tar.bz2 |
mythtv: initial commit for 0.28
Diffstat (limited to 'abs/core/mythtv/stable-0.28/mythplugins')
7 files changed, 386 insertions, 0 deletions
diff --git a/abs/core/mythtv/stable-0.28/mythplugins/PKGBUILD b/abs/core/mythtv/stable-0.28/mythplugins/PKGBUILD new file mode 100644 index 0000000..36fb62d --- /dev/null +++ b/abs/core/mythtv/stable-0.28/mythplugins/PKGBUILD @@ -0,0 +1,125 @@ +pkgbase=mythplugins +pkgname=('mytharchive' + 'mythbrowser' + 'mythgallery' + 'mythgame' + 'mythmusic' + 'mythnetvision' + 'mythnews' + 'mythweather' + 'mythzoneminder') +pkgver=0.28 +pkgrel=1 +arch=('i686' 'x86_64') +url="http://www.mythtv.org" +license=('GPL') +makedepends=('cdrkit' 'dcraw' 'dvdauthor' 'dvd+rw-tools' 'ffmpeg' 'flac' 'libexif' + 'libvorbis' 'mesa' 'libgl' 'mplayer' "mythtv>=${pkgver}" + 'perl-datetime-format-iso8601' 'perl-date-manip' 'perl-image-size' + 'perl-json' 'perl-libwww' 'perl-soap-lite' 'perl-xml-sax' + 'perl-xml-simple' 'perl-xml-xpath' 'python-oauth' 'python2-pillow' + 'python-pycurl' 'zlib') +source=('mythburn.py-aspectratio.patch' 'archivemenu.xml.patch' 'archiveutils.xml.patch' + 'cdparanoia.patch') + +build() { + if [ -e ${srcdir}/mythplugins ] + then + msg "Removing old mythplugins src" + rm -rf ${srcdir}/mythplugins + fi + + cd ${startdir} + msg "Copying in mythplugins git_src" + cp -rp ../git_src/mythtv/mythplugins $srcdir + cd ${srcdir}/${pkgbase} + + msg "Patching configure" + patch -Np1 -i "$srcdir/cdparanoia.patch" + + msg "Configuring mythplugins" + ./configure --prefix=/usr \ + --enable-all \ + --python=/usr/bin/python2 + + msg "Compiling mythplugins" + qmake-qt5 mythplugins.pro || return 1 + make || return 1 +} + +package_mytharchive() { + pkgdesc="Create DVDs or archive recorded shows in MythTV" + depends=('cdrkit' 'dvdauthor' 'dvd+rw-tools' 'ffmpeg' "mythtv>=${pkgver}" + 'mjpegtools' 'python2-pillow') + cd "${srcdir}/${_gitname}/${pkgbase}/mytharchive" + patch mythburn/scripts/mythburn.py < $srcdir/mythburn.py-aspectratio.patch || return 1 + patch theme/menus/archivemenu.xml < $srcdir/archivemenu.xml.patch || return 1 + patch theme/menus/archiveutils.xml < $srcdir/archiveutils.xml.patch || return 1 + make INSTALL_ROOT="${pkgdir}" install || return 1 +} + +package_mythbrowser() { + pkgdesc="Mini web browser for MythTV" + depends=("mythtv>=${pkgver}") + cd "${srcdir}/${_gitname}/${pkgbase}/mythbrowser" + make INSTALL_ROOT="${pkgdir}" install || return 1 +} + +package_mythgallery() { + pkgdesc="Image gallery plugin for MythTV" + depends=('libexif' "mythtv>=${pkgver}" 'dcraw') + cd "${srcdir}/${_gitname}/${pkgbase}/mythgallery" + make INSTALL_ROOT="${pkgdir}" install || return 1 +} + +package_mythgame() { + pkgdesc="Game emulator plugin for MythTV" + depends=("mythtv>=${pkgver}" 'zlib') + cd "${srcdir}/${_gitname}/${pkgbase}/mythgame" + make INSTALL_ROOT="${pkgdir}" install || return 1 +} + +package_mythmusic() { + pkgdesc="Music playing plugin for MythTV" + depends=('cdparanoia' 'fftw' 'flac' 'libcdaudio' 'libcdio-paranoia' + 'libvisual-plugins' 'libvorbis' "mythtv>=${pkgver}" 'taglib') + cd "${srcdir}/${_gitname}/${pkgbase}/mythmusic" + make INSTALL_ROOT="${pkgdir}" install || return 1 +} + +package_mythnetvision() { + pkgdesc="MythNetvision plugin for MythTV" + depends=("mythtv>=${pkgver}" 'python-pycurl' 'python-oauth' + 'python2-lxml' 'python2') + cd "${srcdir}/${_gitname}/${pkgbase}/mythnetvision" + make INSTALL_ROOT="${pkgdir}" install || return 1 +} + +package_mythnews() { + pkgdesc="News checking plugin for MythTV" + depends=("mythtv>=${pkgver}") + cd "${srcdir}/${_gitname}/${pkgbase}/mythnews" + make INSTALL_ROOT="${pkgdir}" install || return 1 +} + +package_mythweather() { + pkgdesc="Weather checking plugin for MythTV" + depends=("mythtv>=${pkgver}" 'perl-date-manip' 'perl-json' 'perl-soap-lite' + 'perl-xml-sax' 'perl-xml-simple' 'perl-xml-xpath' 'perl-image-size' + 'perl-datetime-format-iso8601') + cd "${srcdir}/${_gitname}/${pkgbase}/mythweather" + make INSTALL_ROOT="${pkgdir}" install || return 1 +} + +package_mythzoneminder() { + pkgdesc="View CCTV footage from zoneminder in MythTV" + depends=("mythtv>=${pkgver}") +# install=mythplugins-mythzoneminder.install + cd "${srcdir}/${_gitname}/${pkgbase}/mythzoneminder" + make INSTALL_ROOT="${pkgdir}" install || return 1 +} + +md5sums=('e98c2a09bcb051fdde959fb4bb2e5ab2' + '0364d2613f22943f3d4c9d5ee43c1982' + '1063cf62878cd341476f28f63cb12782' + '5de8dd79d0b8a2b006f3c3258938b6b7') diff --git a/abs/core/mythtv/stable-0.28/mythplugins/__changelog b/abs/core/mythtv/stable-0.28/mythplugins/__changelog new file mode 100644 index 0000000..48cdce8 --- /dev/null +++ b/abs/core/mythtv/stable-0.28/mythplugins/__changelog @@ -0,0 +1 @@ +placeholder diff --git a/abs/core/mythtv/stable-0.28/mythplugins/archivemenu.xml.patch b/abs/core/mythtv/stable-0.28/mythplugins/archivemenu.xml.patch new file mode 100644 index 0000000..f53e9d0 --- /dev/null +++ b/abs/core/mythtv/stable-0.28/mythplugins/archivemenu.xml.patch @@ -0,0 +1,32 @@ +--- archivemenu.xml.orig 2014-02-11 23:01:41.292364208 +0000 ++++ archivemenu.xml 2014-02-11 23:02:13.544892518 +0000 +@@ -3,12 +3,14 @@ + <button> + <type>ARCHIVE_CREATE_DVD</type> + <text>Create DVD</text> ++ <description>Save recordings and videos to video DVD</description> + <action>ARCHIVE_CREATE_DVD</action> + </button> + + <button> + <type>ARCHIVE_CREATE_ARCHIVE</type> + <text>Create Archive</text> ++ <description>Save recordings and videos to a native archive</description> + <action>ARCHIVE_CREATE_ARCHIVE</action> + </button> + +@@ -22,12 +24,14 @@ + <button> + <type>ARCHIVE_IMPORT_VIDEO</type> + <text>Import Archive</text> ++ <description>Import recordings from a native archive</description> + <action>ARCHIVE_IMPORT_VIDEO</action> + </button> + + <button> + <type>ARCHIVE_UTILITIES</type> + <text>Archive Utilities</text> ++ <description>Utilities for MythArchive</description> + <action>MENU archiveutils.xml</action> + </button> + diff --git a/abs/core/mythtv/stable-0.28/mythplugins/archiveutils.xml.patch b/abs/core/mythtv/stable-0.28/mythplugins/archiveutils.xml.patch new file mode 100644 index 0000000..9c17678 --- /dev/null +++ b/abs/core/mythtv/stable-0.28/mythplugins/archiveutils.xml.patch @@ -0,0 +1,27 @@ +--- archiveutils.xml.orig 2014-02-11 23:01:41.292364208 +0000 ++++ archiveutils.xml 2014-02-11 23:02:13.544892518 +0000 +@@ -2,19 +2,22 @@ + + <button> + <type>ARCHIVE_LAST_LOG</type> +- <text>Show Log Viewer</text> ++ <text>Log Viewer</text> ++ <description>Show the Archive Log Viewer</description> + <action>ARCHIVE_LAST_LOG</action> + </button> + + <button> + <type>ARCHIVE_TEST_DVD</type> + <text>Play Created DVD</text> ++ <description>Play the last created archive DVD</description> + <action>ARCHIVE_TEST_DVD</action> + </button> + + <button> + <type>ARCHIVE_BURN_DVD</type> +- <text>Burn DVD</text> ++ <text>Burn Created DVD</text> ++ <description>Burn the last created archive to DVD</description> + <action>ARCHIVE_BURN_DVD</action> + </button> + diff --git a/abs/core/mythtv/stable-0.28/mythplugins/cdparanoia.patch b/abs/core/mythtv/stable-0.28/mythplugins/cdparanoia.patch new file mode 100644 index 0000000..b4d1449 --- /dev/null +++ b/abs/core/mythtv/stable-0.28/mythplugins/cdparanoia.patch @@ -0,0 +1,52 @@ +diff -Nru a/configure b/configure +--- a/configure 2012-10-02 23:30:24.000000000 +1300 ++++ b/configure 2013-01-09 14:54:40.448916370 +1300 +@@ -649,7 +649,7 @@ + echo "MythMusic requires FLAC." + fi + +- if ! check_lib cdio/cdio.h cdio_open -lcdio || ! check_lib cdio/cdda.h cdio_cddap_open -lcdio_cdda || ! check_lib cdio/paranoia.h cdio_paranoia_init -lcdio_paranoia ; then ++ if ! check_lib cdio/cdio.h cdio_open -lcdio || ! check_lib cdio/paranoia/cdda.h cdio_cddap_open -lcdio_cdda || ! check_lib cdio/paranoia/paranoia.h cdio_paranoia_init -lcdio_paranoia ; then + disable cdio + fi + +diff -Nru a/mythmusic/mythmusic/cddecoder.cpp b/mythmusic/mythmusic/cddecoder.cpp +--- a/mythmusic/mythmusic/cddecoder.cpp 2012-10-02 23:30:24.000000000 +1300 ++++ b/mythmusic/mythmusic/cddecoder.cpp 2013-01-09 14:53:37.031690618 +1300 +@@ -14,7 +14,7 @@ + #include <QString> + + // libcdio +-#include <cdio/cdda.h> ++#include <cdio/paranoia/cdda.h> + #include <cdio/logging.h> + + // MythTV +diff -Nru a/mythmusic/mythmusic/cddecoder.h b/mythmusic/mythmusic/cddecoder.h +--- a/mythmusic/mythmusic/cddecoder.h 2012-10-02 23:30:24.000000000 +1300 ++++ b/mythmusic/mythmusic/cddecoder.h 2013-01-09 14:53:12.328140979 +1300 +@@ -11,8 +11,8 @@ + #endif + + #ifdef HAVE_CDIO +-# include <cdio/cdda.h> +-# include <cdio/paranoia.h> ++# include <cdio/paranoia/cdda.h> ++# include <cdio/paranoia/paranoia.h> + #endif + + class Metadata; +diff -Nru a/mythmusic/mythmusic/cdrip.cpp b/mythmusic/mythmusic/cdrip.cpp +--- a/mythmusic/mythmusic/cdrip.cpp 2012-10-02 23:30:24.000000000 +1300 ++++ b/mythmusic/mythmusic/cdrip.cpp 2013-01-09 14:54:11.815330268 +1300 +@@ -8,8 +8,8 @@ + + #include "config.h" + #ifdef HAVE_CDIO +-# include <cdio/cdda.h> +-# include <cdio/paranoia.h> ++# include <cdio/paranoia/cdda.h> ++# include <cdio/paranoia/paranoia.h> + #endif //def HAVE_CDIO + + // C++ includes diff --git a/abs/core/mythtv/stable-0.28/mythplugins/mythburn.py-aspectratio.patch b/abs/core/mythtv/stable-0.28/mythplugins/mythburn.py-aspectratio.patch new file mode 100644 index 0000000..377de95 --- /dev/null +++ b/abs/core/mythtv/stable-0.28/mythplugins/mythburn.py-aspectratio.patch @@ -0,0 +1,138 @@ +--- mythburn.py.orig 2013-12-16 22:41:31.532703825 +0000 ++++ mythburn.py 2013-12-16 22:40:52.191109409 +0000 +@@ -98,6 +98,7 @@ + from fcntl import ioctl + import CDROM + from shutil import copy ++from subprocess import Popen, PIPE + + import MythTV + from MythTV import datetime +@@ -440,7 +441,7 @@ + os.remove(os.path.join(root, name)) + + ############################################################# +-# Romoves all the objects from a directory ++# Removes all the objects from a directory + + def deleteEverythingInFolder(folder): + for root, dirs, files in os.walk(folder, topdown=False): +@@ -666,14 +667,14 @@ + # Gets the aspect ratio of a video file from its stream info file + + def getAspectRatioOfVideo(index): +- """Returns the aspect ratio of the video file (1.333, 1.778, etc)""" ++ """Returns the aspect ratio of the original video file (1.333, 1.778, etc)""" + + #open the XML containing information about this file +- infoDOM = xml.dom.minidom.parse(os.path.join(getItemTempPath(index), 'streaminfo.xml')) ++ infoDOM = xml.dom.minidom.parse(os.path.join(getItemTempPath(index), 'streaminfo_orig.xml')) + + #error out if its the wrong XML + if infoDOM.documentElement.tagName != "file": +- fatalError("Stream info file doesn't look right (%s)" % os.path.join(getItemTempPath(index), 'streaminfo.xml')) ++ fatalError("Stream info file doesn't look right (%s)" % os.path.join(getItemTempPath(index), 'streaminfo_orig.xml')) + video = infoDOM.getElementsByTagName("file")[0].getElementsByTagName("streams")[0].getElementsByTagName("video")[0] + if video.attributes["aspectratio"].value != 'N/A': + aspect_ratio = float(video.attributes["aspectratio"].value) +@@ -1695,6 +1696,37 @@ + fatalError("Failed while running mytharchivehelper to get stream information.\n" + "Result: %d, Command was %s" % (result, command)) + ++ #open the XML containing information about this file ++ infoDOM = xml.dom.minidom.parse(xmlFilename) ++ ++ #error out if its the wrong XML ++ if infoDOM.documentElement.tagName != "file": ++ fatalError("This info file doesn't look right (%s)." % xmlFilename) ++ ++ file = infoDOM.getElementsByTagName("file")[0] ++ video = infoDOM.getElementsByTagName("file")[0].getElementsByTagName("streams")[0].getElementsByTagName("video")[0] ++ ++ #use ffmpeg to get display aspect ratio (DAR) of video ++ cmd = "mythffmpeg -i " + quoteCmdArg(file.attributes["filename"].value) + " 2>&1" ++ aspect_ratio = Popen(cmd, shell=True, stdout=PIPE).stdout.read() ++ if "DAR" in aspect_ratio: ++ #clean DAR string ++ aspect_ratio = aspect_ratio.split("DAR ")[-1].split(",")[0] ++ aspect_ratio = ''.join([c for c in aspect_ratio if c in '1234567890:']).split(":") ++ else: ++ #calculate aspect from video size ++ aspect_ratio = getVideoSize(xmlFilename) ++ ++ #convert to decimal+ ++ aspect_ratio = float(aspect_ratio[0]) / float(aspect_ratio[1]) ++ ++ write("Video %s aspect ratio is: %s" % (filename, aspect_ratio)) ++ ++ #set aspect ratio ++ video.setAttribute("aspectratio",str(aspect_ratio)) ++ ++ WriteXMLToFile (infoDOM,xmlFilename) ++ + # print out the streaminfo.xml file to the log + infoDOM = xml.dom.minidom.parse(xmlFilename) + write(xmlFilename + ":-\n" + infoDOM.toprettyxml(" ", ""), False) +@@ -2010,7 +2042,7 @@ + ############################################################# + # Re-encodes a file to mpeg2 + +-def encodeVideoToMPEG2(source, destvideofile, video, audio1, audio2, aspectratio, profile): ++def encodeVideoToMPEG2(source, destvideofile, video, folder, audio1, audio2, aspectratio, profile): + """Encodes an unknown video source file eg. AVI to MPEG2 video and AC3 audio, use mythffmpeg""" + + profileNode = findEncodingProfile(profile) +@@ -2035,6 +2067,35 @@ + value = quoteCmdArg(destvideofile) + if value == "%aspect": + value = aspectratio ++ if value == "720x480" or value == "720x576": ++ videores, fps, videoAR = getVideoParams(folder) ++ videoWidth = int(videores.split("x")[0]) ++ videoHeight = int(videores.split("x")[1]) ++ ++ #add padding to correct for aspects > than 1.9:1 ++ if float(videoAR) >= 1.9: ++ #check which video type and set the correct height ++ if videomode == "ntsc": ++ videoModeHeight = 480 ++ else: ++ videoModeHeight = 576 ++ ++ #calculate the video height based on the aspect ratio of the video ++ #multiply by 1.185 to compensate for dvds non-square pixels ++ calVideoHeight = int(round((720 / float(videoAR)) * 1.185)) ++ if calVideoHeight % 2 == 1: ++ calVideoHeight = calVideoHeight + 1 ++ #write("calVideoHeight: %s" % calVideoHeight) ++ ++ #use original video height if the calculated video height is close ++ if (calVideoHeight + 20 < videoHeight) or (calVideoHeight - 20 > videoHeight): ++ videoHeight = calVideoHeight ++ ++ cropPixels = videoModeHeight - videoHeight ++ ++ write("Crop Pixels Total: %s" % cropPixels) ++ name = "-vf" ++ value = "\"scale=720:%d, setsar=1:1, pad=720:%d:0:%d:black\"" % (videoModeHeight - cropPixels, videoModeHeight, cropPixels / 2) + + # only re-encode the audio if it is not already in AC3 format + if audio1[AUDIO_CODEC] == "AC3": +@@ -4608,7 +4669,7 @@ + + #do the re-encode + encodeVideoToMPEG2(mediafile, os.path.join(folder, "newfile2.mpg"), video, +- audio1, audio2, aspectratio, profile) ++ folder, audio1, audio2, aspectratio, profile) + mediafile = os.path.join(folder, 'newfile2.mpg') + + #remove the old mediafile that was run through mythtranscode +@@ -4762,7 +4823,7 @@ + + #do the re-encode + encodeVideoToMPEG2(mediafile, os.path.join(folder, "newfile2.mpg"), video, +- audio1, audio2, aspectratio, profile) ++ folder, audio1, audio2, aspectratio, profile) + mediafile = os.path.join(folder, 'newfile2.mpg') + + #remove an intermediate file diff --git a/abs/core/mythtv/stable-0.28/mythplugins/mythplugins-mythzoneminder.install b/abs/core/mythtv/stable-0.28/mythplugins/mythplugins-mythzoneminder.install new file mode 100644 index 0000000..a4e0c0d --- /dev/null +++ b/abs/core/mythtv/stable-0.28/mythplugins/mythplugins-mythzoneminder.install @@ -0,0 +1,11 @@ +post_install() { + . /etc/systemconfig + if [ $SystemType = Master_backend -o $SystemType = Standalone ] + then + echo "This looks a zoneminder server install" + echo "Installing zoneminder" + #for reference the pacman statement below will not work because of a db lock. + pacman -S zoneminder + fi + +} |