updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / exaile-cn / PKGBUILD
blob472847727de4c1d56b5967a88ee90ae710da202e
1 # Maintainer:  cuihao <cuihao dot leo at gmail dot com>
2 # Contributor: Leo Zhao <zhao78977@gmail.com>
4 # PKGBUILD of Exaile:
5 # https://aur.archlinux.org/packages/ex/exaile/PKGBUILD
7 pkgname=exaile-cn
8 _pkgname=exaile
9 pkgver=100721
10 _pkgver=0.3.2.0
11 pkgrel=2
12 pkgdesc='Exaile mod for Chinese users.'
13 url='https://exaile-cn.googlecode.com/'
14 license=('GPL')
15 arch=('i686' 'x86_64')
16 depends=('python2-chardet'
17          'gstreamer0.10-python'
18          'gstreamer0.10-good-plugins'
19          'mutagen'
20          'dbus-python'
21          'pygtk>=2.10'
22          'librsvg')
23 makedepends=('help2man')
24 optdepends=('pycddb: CD metadata retrieval'
25             'python2-bsddb: music collection support'
26             'gstreamer0.10-bad-plugins: support for more formats'
27             'gstreamer0.10-ugly-plugins: support for more formats'
28             'gstreamer0.10-ffmpeg: support for more formats')
29 conflicts=('exaile')
30 provides=('exaile=0.3.2.0')
31 install=${_pkgname}.install
32 source=("${url}/files/exaile-cn${pkgver}.tar.gz"
33         "https://www.launchpad.net/${_pkgname}/${_pkgver%.*}/${_pkgver}/+download/${_pkgname}-${_pkgver}.tar.gz"
34         "${url}/files/lrcMod.py"
35         "${url}/files/Panel.py")
36 sha1sums=('c474561cb7a46a2f40ce94dde516065fc857d9c8'
37           '08015ab647f5b83997bd2f1c87c14d3d287fd3e7'
38           '2bf4c513cb6877a1e1d3cb0239646cc84e0cbcb6'
39           '260d490b4cc77df1a5bc8fe9c1b8656272ca5ed8')
41 build() {
42 ### exaile-cn
43     cd "${srcdir}/exaile-cn${pkgver}"
44     exaile_path="${srcdir}/${_pkgname}-${_pkgver}/"
46 # 解决乱码问题方法
47     cp -f _id3.py "${exaile_path}/xl/metadata/"
49 # 豆瓣封面插件
50     cp -r doubancovers "${exaile_path}/plugins/"
52 # 歌词同步显示插件
53     cp -r LyricDisp "${exaile_path}/plugins/"
54     cp -f engine_unified.py engine_normal.py "${exaile_path}/xl/player/"
56 # 面板标签竖行显示
57     cp -f __init__.py "${exaile_path}/xlgui/"
59 # 豆瓣电台插件
60     cp -f track.py "${exaile_path}/xl/trax/"
61     cp -r doubanfm "${exaile_path}/plugins/"
62     
63 # 补丁 谷歌音乐歌词支持
64     cp -f "${srcdir}/lrcMod.py" "${exaile_path}/plugins/LyricDisp/"
66 # 补丁 查找音乐文件夹下歌词
67     cp -f "${srcdir}/Panel.py" "${exaile_path}/plugins/LyricDisp/disp/Panel.py"
68     
69 ### exaile
70     cd "${srcdir}/${_pkgname}-${_pkgver}"
72     # python2 fix
73     for file in $(find . -name Makefile -print) tools/generate-launcher; do
74         sed -i 's_python_python2_' $file
75     done
77     for file in plugins/*/*.py plugins/*.py exaile.py; do
78         sed -i 's_#![ ]*/usr/bin/python_#!/usr/bin/python2_' $file
79         sed -i 's_#![ ]*/usr/bin/env python_#!/usr/bin/python2_' $file
80     done
82     make
83     make PREFIX=/usr DESTDIR="${pkgdir}" install
86 #package() {
87 #    cd "${srcdir}/${_pkgname}-${_pkgver}"