Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Maintainer: Jannik Sost <jannik.sost at gmail.com>
- # Contributor: Jonathan Conder <[email protected]>
- # Contributor: Giovanni Scafora <[email protected]>
- # Contributor: Juergen Hoetzel <[email protected]>
- # Contributor: <[email protected]>
- # Contributor: dorphell <[email protected]>
- pkgname=('mythtv-0.24-fixes-git'
- ###
- # Un-comment (remove hash) in front of the next lines,
- # to build mythplugins, too.
- ###
- #'mythplugins-0.24-fixes-git-mytharchive'
- #'mythplugins-0.24-fixes-git-mythbrowser'
- #'mythplugins-0.24-fixes-git-mythgallery'
- #'mythplugins-0.24-fixes-git-mythgame'
- #'mythplugins-0.24-fixes-git-mythmusic'
- #'mythplugins-0.24-fixes-git-mythnetvision'
- #'mythplugins-0.24-fixes-git-mythnews'
- #'mythplugins-0.24-fixes-git-mythvideo'
- #'mythplugins-0.24-fixes-git-mythweather'
- #'mythplugins-0.24-fixes-git-mythzoneminder'
- )
- pkgver=20101221
- pkgrel=1
- pkgdesc="A Homebrew PVR project. Including MythPlugins (Edit PKGBUILD, please!)"
- arch=('i686' 'x86_64')
- url="http://www.mythtv.org/"
- license=('GPL')
- depends=('lame' 'libavc1394' 'libiec61883' 'libvdpau' 'libxinerama' 'libxvmc'
- 'lirc-utils' 'mesa' 'mysql-clients' 'mysql-python' 'perl-dbd-mysql'
- 'perl-libwww' 'perl-net-upnp' 'python-lxml' 'qt' 'wget')
- makedepends=('yasm' 'subversion')
- #If we only build MythTV, we don't need all those makedepends. So detect if we need them.
- for name in ${pkgname[@]} ; do
- if [[ $name == mythplugins-0.24-fixes-git-* ]] ; then
- makedepends=('yasm' 'git'
- 'cdrkit' 'dvdauthor' 'dvd+rw-tools' 'ffmpeg'
- 'python-imaging' 'libexif' 'perl-date-manip' 'zlib' 'cdparanoia'
- 'flac' 'libcdaudio' 'libvisual' 'libvorbis' 'sdl' 'taglib'
- 'python2-oauth' 'python-pycurl' 'mplayer' 'perl-date-manip'
- 'perl-libwww' 'perl-soap-lite' 'perl-xml-sax' 'perl-xml-simple'
- 'perl-xml-xpath' 'perl-image-size' 'perl-datetime-format-iso8601'
- 'subversion'
- )
- break
- fi;
- done
- conflicts=('mythtv' 'mythtv-0.24-fixes-git')
- provides=('mythtv' 'mythtv-0.24-fixes-svn')
- optdepends=('xmltv: to download tv listings')
- options=('force')
- install='mythtv.install'
- source=('mythbackend.rc'
- 'mythbackend.conf'
- 'mtd.rc')
- md5sums=('feadcc9ad064d93d6dceab1efc0bd9ed'
- 'bb8e4033d82428d827570fae9ba15e6a'
- '476c12ba074794ad7f4ae092bdf949d6')
- _gitroot="git://github.com/MythTV/mythtv.git"
- _gitname=mythtv
- build() {
- cd "$srcdir"
- msg "Connecting to GIT server...."
- if [ -d $_gitname ] ; then
- cd $_gitname && git pull origin
- msg "The local files are updated."
- else
- git clone -b "fixes/0.24" $_gitroot $_gitname
- fi
- msg "GIT checkout done or server timeout"
- msg "Starting make..."
- rm -rf "$srcdir/$_gitname-build"
- git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
- cd "$srcdir/$_gitname-build/mythtv"
- find 'bindings/python' 'contrib' -type f | xargs sed -i 's@^#!.*python$@#!/usr/bin/python2@'
- ARCH="${CARCH/_/-}"
- ./configure --prefix=/usr --cpu="$ARCH" \
- --enable-mmx \
- --enable-audio-oss \
- --enable-audio-alsa \
- --disable-audio-jack \
- --disable-audio-pulse \
- --disable-altivec \
- --disable-distcc \
- --disable-ccache \
- --enable-vdpau \
- --enable-dvb \
- --dvb-path=/usr/include \
- --enable-lirc \
- --enable-joystick-menu \
- --enable-v4l \
- --enable-ivtv \
- --enable-xvmc \
- --enable-xvmcw \
- --enable-xvmc-vld \
- --enable-firewire \
- --enable-opengl-vsync \
- --enable-xrandr \
- --enable-xv \
- --enable-x11 \
- --with-bindings=perl,python --python=python2
- make
- #Build MythPlugins only if at least one plugins is selected
- for name in ${pkgname[@]} ; do
- if [[ $name == mythplugins-0.24-fixes-git-* ]] ; then
- cd "$srcdir/$_gitname-build/mythplugins"
- find . -name '*.py' -type f | xargs sed -i 's@^#!.*python$@#!/usr/bin/python2@'
- ./configure --prefix=/usr \
- --enable-all \
- --python=python2
- qmake mythplugins.pro
- make
- break
- fi;
- done
- }
- package_mythtv-0.24-fixes-git() {
- backup=('etc/conf.d/mythbackend')
- cd "$srcdir/$_gitname-build/mythtv"
- make INSTALL_ROOT="$pkgdir" install
- install -D -m755 "$srcdir/mythbackend.rc" "$pkgdir/etc/rc.d/mythbackend"
- install -D -m644 "$srcdir/mythbackend.conf" "$pkgdir/etc/conf.d/mythbackend"
- install -D -m644 'database/mc.sql' "$pkgdir/usr/share/mythtv/mc.sql"
- mkdir -p "$pkgdir/usr/share/mythtv/contrib"
- # This is not ideal, as it will include the .git directory when copying
- # But you may remove /usr/share/mythtv/contrib/.git after the you installed this package
- cp -R 'contrib/'* "$pkgdir/usr/share/mythtv"
- }
- package_mythplugins-0.24-fixes-git-mytharchive() {
- pkgdesc="Create DVDs or archive recorded shows in MythTV"
- depends=("mythtv-0.24-fixes-git" 'cdrkit' 'dvdauthor' 'dvd+rw-tools' 'ffmpeg'
- 'python-imaging')
- conflicts=('mythplugins-mytharchive' 'mythplugins-0.24-fixes-svn-mytharchive')
- provides=('mythplugins-mytharchive')
- cd "$srcdir/$_gitname-build/mythplugins/mytharchive"
- make INSTALL_ROOT="$pkgdir" install
- }
- package_mythplugins-0.24-fixes-git-mythbrowser() {
- pkgdesc="Mini web browser for MythTV"
- depends=("mythtv-0.24-fixes-git")
- conflicts=('mythplugins-mythbrowser' 'mythplugins-0.24-fixes-svn-mythbrowser')
- provides=('mythplugins-mythbrowser')
- cd "$srcdir/$_gitname-build/mythplugins/mythbrowser"
- make INSTALL_ROOT="$pkgdir" install
- }
- package_mythplugins-0.24-fixes-git-mythgallery() {
- pkgdesc="Image gallery plugin for MythTV"
- depends=("mythtv-0.24-fixes-git" 'libexif')
- conflicts=('mythplugins-mythgallery' 'mythplugins-0.24-fixes-svn-mythgallery')
- provides=('mythplugins-mythgallery')
- cd "$srcdir/$_gitname-build/mythplugins/mythgallery"
- make INSTALL_ROOT="$pkgdir" install
- }
- package_mythplugins-0.24-fixes-git-mythgame() {
- pkgdesc="Game emulator plugin for MythTV"
- depends=("mythtv-0.24-fixes-git")
- conflicts=('mythplugins-mythgame' 'mythplugins-0.24-fixes-svn-mythgame')
- provides=('mythplugins-mythgame')
- cd "$srcdir/$_gitname-build/mythplugins/mythgame"
- make INSTALL_ROOT="$pkgdir" install
- }
- package_mythplugins-0.24-fixes-git-mythmusic() {
- pkgdesc="Music playing plugin for MythTV"
- depends=("mythtv-0.24-fixes-git" 'cdparanoia' 'flac' 'libcdaudio' 'libvisual'
- 'libvorbis' 'sdl' 'taglib')
- conflicts=('mythplugins-mythmusic' 'mythplugins-0.24-fixes-svn-mythmusic')
- provides=('mythplugins-mythmusic')
- cd "$srcdir/$_gitname-build/mythplugins/mythmusic"
- make INSTALL_ROOT="$pkgdir" install
- }
- package_mythplugins-0.24-fixes-git-mythnetvision() {
- pkgdesc="MythNetvision plugin for MythTV"
- depends=("mythtv-0.24-fixes-git" 'python2-oauth' 'python-pycurl')
- conflicts=('mythplugins-mythnetvision' 'mythplugins-0.24-fixes-svn-mythnetvision')
- provides=('mythplugins-mythnetvision')
- cd "$srcdir/$_gitname-build/mythplugins/mythnetvision"
- make INSTALL_ROOT="$pkgdir" install
- }
- package_mythplugins-0.24-fixes-git-mythnews() {
- pkgdesc="News checking plugin for MythTV"
- depends=("mythtv-0.24-fixes-git")
- conflicts=('mythplugins-mythnews' 'mythplugins-0.24-fixes-svn-mythnews')
- provides=('mythplugins-mythnews')
- cd "$srcdir/$_gitname-build/mythplugins/mythnews"
- make INSTALL_ROOT="$pkgdir" install
- }
- package_mythplugins-0.24-fixes-git-mythvideo() {
- pkgdesc="Video playback and browsing plugin for MythTV"
- depends=("mythtv-0.24-fixes-git" 'mplayer')
- conflicts=('mythplugins-mythvideo' 'mythplugins-0.24-fixes-svn-mythvideo')
- provides=('mythplugins-mythvideo')
- cd "$srcdir/$_gitname-build/mythplugins/mythvideo"
- make INSTALL_ROOT="$pkgdir" install
- install -D -m755 "$srcdir/mtd.rc" "$pkgdir/etc/rc.d/mtd"
- }
- package_mythplugins-0.24-fixes-git-mythweather() {
- pkgdesc="Weather checking plugin for MythTV"
- depends=("mythtv-0.24-fixes-git" 'perl-date-manip' 'perl-libwww' 'perl-soap-lite'
- 'perl-xml-sax' 'perl-xml-simple' 'perl-xml-xpath' 'perl-image-size'
- 'perl-datetime-format-iso8601')
- conflicts=('mythplugins-mythweather' 'mythplugins-0.24-fixes-svn-mythweather')
- provides=('mythplugins-mythweather')
- cd "$srcdir/$_gitname-build/mythplugins/mythweather"
- make INSTALL_ROOT="$pkgdir" install
- }
- package_mythplugins-0.24-fixes-git-mythzoneminder() {
- pkgdesc="View CCTV footage from zoneminder in MythTV"
- depends=("mythtv-0.24-fixes-git")
- conflicts=('mythplugins-mythzoneminder' 'mythplugins-0.24-fixes-svn-mythzoneminder')
- provides=('mythplugins-mythzoneminder')
- install='mythplugins-mythzoneminder.install'
- cd "$srcdir/$_gitname-build/mythplugins/mythzoneminder"
- make INSTALL_ROOT="$pkgdir" install
- }
- #pkgdesc again, for AUR parser
- pkgdesc="A Homebrew PVR project. Including MythPlugins (Edit PKGBUILD, please!)"
Advertisement
Add Comment
Please, Sign In to add comment