summaryrefslogtreecommitdiff
path: root/extra/totem/PKGBUILD
blob: 23078e19ef0386b758b2365d708a4547d94d79f0 (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
# $Id: PKGBUILD 173078 2012-12-10 11:38:58Z jgc $
# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
# Contributor: Jan de Groot <jgc@archlinux.org>

pkgbase=totem
pkgname=('totem' 'totem-plugin')
pkgver=3.6.3
pkgrel=2.1
pkgdesc="GNOME3 movie player based on GStreamer"
url="http://www.gnome.org"
arch=('i686' 'x86_64' 'mips64el')
license=(GPL2 custom)
depends=(gst-plugins-base gst-plugins-good totem-plparser desktop-file-utils iso-codes libpeas
         hicolor-icon-theme gnome-icon-theme-symbolic gsettings-desktop-schemas dconf clutter-gst
         clutter-gtk python2-gobject gst-plugins-bad)
makedepends=(intltool gnome-doc-utils nautilus vala grilo pylint dbus-glib libzeitgeist)
[ "$CARCH" != "mips64el" ] && makedepends+=('lirc-utils')
options=('!libtool' '!emptydirs')
source=(http://ftp.gnome.org/pub/gnome/sources/$pkgbase/${pkgver%.*}/$pkgbase-$pkgver.tar.xz
        browser-plugins.ini)
sha256sums=('ad9f2ff207c8a965975670e262394953b37b2dc25cff7ee59f138f961f88ce60'
            'a50a3bbf35f0535f7e8e20af1893446a2e5711015484f9ae6d1ff91af3b23c4e')

build() {
  cd "$pkgbase-$pkgver"
  ./configure --prefix=/usr \
    --sysconfdir=/etc \
    --libexecdir=/usr/lib/totem \
    --localstatedir=/var \
    --disable-static \
    --enable-python \
    --enable-nautilus
  make
}

package_totem() {
  groups=(gnome-extra)
  install=totem.install
  optdepends=('gst-plugins-ugly: Extra media codecs'
              'gst-ffmpeg: Extra media codecs'
              'grilo-plugins: Browse sidebar (remote media)'
              'pyxdg: opensubtitles plugin'
              'libzeitgeist: Zeitgeist plugin')

  cd "$pkgbase-$pkgver"
  make DESTDIR="${pkgdir}" install

  rm -r "$pkgdir/usr/lib/mozilla"
  rm "$pkgdir/usr/lib/totem/totem-plugin-viewer"

  sed -i "s|#!/usr/bin/python$|#!/usr/bin/python2|" \
    $pkgdir/usr/lib/totem/totem/totem-bugreport.py

  install -Dm644 COPYING "$pkgdir/usr/share/licenses/totem/COPYING"
}

package_totem-plugin() {
  pkgdesc="Totem plugin for web browsers"
  depends=("totem=$pkgver" dbus-glib)
  backup=(etc/totem/browser-plugins.ini)

  cd "$pkgbase-$pkgver"
  make -C browser-plugin \
    plugindir=/usr/lib/mozilla/plugins \
    xptdir=/usr/lib/mozilla/plugins \
    DESTDIR="$pkgdir" install
  
  install -Dm644 ../browser-plugins.ini "$pkgdir/etc/totem/browser-plugins.ini"

  install -Dm644 COPYING "$pkgdir/usr/share/licenses/totem-plugin/COPYING"
}