summaryrefslogtreecommitdiffstats
path: root/abs/core/mythtv/stable-29/mythplugins/PKGBUILD
blob: 57288c0aa72f453a477586382d2717b4e414716e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
pkgbase=mythplugins
pkgname=('mytharchive'
         'mythbrowser'
         'mythgallery'
         'mythgame'
         'mythmusic'
         'mythnetvision'
         'mythnews'
         'mythweather'
         'mythzoneminder')
pkgver=29.1
pkgrel=12
arch=('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' 'python2-oauth' 'python2-pillow'
             'python2-pycurl' 'zlib')
source=('mythburn.py-aspectratio.patch'
        'mythburn.cpp-python2.patch'
        'cdparanoia.patch'
        '0317-0336-MythMusic-Fix-Playlist-copyTracks-and-removeAllTrack.patch'
        )

prepare() {
    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}
    patch -Np1 -i "$srcdir/0317-0336-MythMusic-Fix-Playlist-copyTracks-and-removeAllTrack.patch"

    msg "Change python to python2"
    find . -name '*.py' -type f | xargs sed -i 's@^#!.*python$@#!/usr/bin/python2@'
    patch -Np1 -i "$srcdir/mythburn.cpp-python2.patch"

    msg "Patching Configure"
    cd ${srcdir}/${pkgbase}
    patch -Np1 -i "$srcdir/cdparanoia.patch"
}

build() {
    cd ${srcdir}/${pkgbase}
    msg "Configuring mythplugins"
    ./configure --prefix=/usr \
                --enable-all \
                --python=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}"
             'm2vrequantiser' 'mjpegtools' 'python2-pillow')
    optdepends=('projectx: for subtitle support')
    cd "${srcdir}/${_gitname}/${pkgbase}/mytharchive"
    patch mythburn/scripts/mythburn.py < $srcdir/mythburn.py-aspectratio.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}" 'python2-pycurl' 'python2-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'
         'b9edd8f7da64ffa74baa91092bd48cc9'
         '5de8dd79d0b8a2b006f3c3258938b6b7'
         '0299d0214c0d3a452c0284352435d698')