summaryrefslogtreecommitdiff
path: root/libre/clementine-libre/PKGBUILD
blob: b41c4e40a0e64661225c00000596dfbc78a3a594 (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
# $Id: PKGBUILD 98608 2013-10-15 14:50:08Z alucryd $
# Maintainer: Maxime Gauduin <alucryd@gmail.com>
# Contributor: Stéphane Gaudreault <stephane@archlinux.org>
# Contributor: BlackEagle <ike.devolder@gmail.com>
# Contributor: Dany Martineau <dany.luc.martineau@gmail.com>
# Maintainer (Parabola): André Silva <emulatorman@lavabit.com>
# Contributor (Parabola): Kete <kete@ninthfloor.org>
# Contributor (Parabola): Márcio Silva <coadde@lavabit.com>

_pkgname=clementine
pkgname=clementine-libre
pkgver=1.2.0
pkgrel=1
pkgdesc="A music player and library organizer, without nonfree artwork and spotify support"
url="http://www.clementine-player.org/"
license=('GPL')
arch=('i686' 'x86_64')
depends=('chromaprint' 'glew' 'gstreamer0.10-base' 'libcdio' 'libgpod' 'liblastfm' 'libmtp' 'libmygpo-qt' 'protobuf' 'qca-ossl' 'taglib')
makedepends=('cmake' 'boost' 'mesa' 'sparsehash')
optdepends=('gstreamer0.10-base-plugins: "Base" plugin libraries'
            'gstreamer0.10-good-plugins: "Good" plugin libraries'
            'gstreamer0.10-bad-libre-plugins: "Bad" plugin libraries'
            'gstreamer0.10-ugly-plugins: "Ugly" plugin libraries'
            'gvfs: Various devices support')
replaces=('clementine')
conflicts=('clementine')
provides=("clementine=$pkgver")
install=clementine.install
source=("http://clementine-player.googlecode.com/files/${_pkgname}-${pkgver}.tar.gz"
        'clementine-1.1.1-libimobiledevice-fix.patch'
        'remove-nonfree-artwork-and-spotify.patch'
        'moognu.png')
sha256sums=('563d00da4e893f7b1966ed137bcab28042151e31ea561cb7076047d3cad96f72'
            '688bdd15c898cb198dc85d58e2dedcca33771e374b4c6b621be723bafc167590'
            '23f3b5022e8936b1a7bbf2c63f61fe308c5f215664e3b8ba2d1520b579db24e6'
            'c6918617769152f3617c61f721819e69d03f671b85760b11cfe45abd53955bc4')

prepare() {
  cd ${_pkgname}-${pkgver}

  patch -Np1 -i ../clementine-1.1.1-libimobiledevice-fix.patch

  # remove nonfree nonfree artwork and spotify references on files
  patch -Np1 -i ../remove-nonfree-artwork-and-spotify.patch

  # remove nonfree spotifyblob folders
  rm -rv ext/{clementine-spotifyblob,libclementine-spotifyblob}

  # remove nonfree spotify files
  rm -v cmake/SpotifyVersion.cmake
  rm -v data/spotify-core-logo-128x128.png
  rm -v data/icons/svg/spotify.svg
  rm -v data/schema/schema-30.sql
  rm -v src/{globalsearch/spotifysearchprovider.{cpp,h},internet/spotify{blobdownloader.{cpp,h},server.{cpp,h},service.{cpp,h},settingspage.{cpp,h,ui}}}

  ## remove nonfree nyancat.png
  rm -v data/nyancat.png

  ## rut moognu.png to the source code
  install -m644 -v ../moognu.png data

  # create a blank file due which is a dependency for clementine
  touch data/schema/schema-30.sql  
}

build() {
  cd ${_pkgname}-${pkgver}

  if [[ -d build ]]; then
    rm -rf build
  fi
  mkdir build && cd build

  cmake .. -DCMAKE_INSTALL_PREFIX='/usr' -DCMAKE_BUILD_TYPE='Release'
  make
}

package() {
  cd ${_pkgname}-${pkgver}/build

  make DESTDIR="${pkgdir}" install
}

# vim: ts=2 sw=2 et: