1 # Author: Moligaloo <Moligaloo@gmail.com>
2 # Maintainer: Yangtse <yangtsesu@gmail.com>
3 # Contributor: Vehiclee <>
4 # Contributor: Iven Day <ivenvd@gmail.com>
5 # Contributor: abf <zouxiaomingabf@gmail.com>
10 pkgdesc="An open source online version of the famous board game Sanguosha"
11 arch=('i686' 'x86_64')
12 url="https://github.com/Moligaloo/QSanguosha"
14 depends=('qt' 'phonon' 'plib' 'lua')
15 makedepends=('gcc' 'make' 'git' 'swig')
16 source=('qsanguosha' 'qsanguosha.desktop' 'sgs.png')
17 conflicts=(qsanguosha)
19 install=qsanguosha.install
21 md5sums=('49ccb51ea1ba979f8c8b469b122f69d6'
22 'c8180a5a852ea23f194f49e60e2b0b02'
23 'c727b12c3a46b56fd0151eae5ef4c6c5')
25 _gitroot=https://github.com/Moligaloo/QSanguosha.git
30 if [ -d ${_gitname} ]; then
31 cd ${_gitname} && git pull origin
32 msg "The local files are updated."
37 msg "GIT checkout done or server timeout"
38 msg "Starting make..."
40 cd ${srcdir}/${_gitname}/swig
41 swig -c++ -lua sanguosha.i
42 cd ${srcdir}/${_gitname}
45 lrelease QSanguosha.pro
46 mkdir -p ${pkgdir}/opt/qsanguosha
47 cp -R {lib,font,doc,audio,diy,etc,extension-doc,QSanguosha,qt_zh_CN.qm,backdrop,image,lang,scenarios,lua,sanguosha.lua,sanguosha.qm,sanguosha.qss} ${pkgdir}/opt/qsanguosha/
48 install -D -m755 ${srcdir}/qsanguosha "${pkgdir}/usr/bin/qsanguosha"
49 install -D -m644 ${srcdir}/qsanguosha.desktop "${pkgdir}/usr/share/applications/qsanguosha.desktop"
50 install -D -m644 ${srcdir}/sgs.png "${pkgdir}/usr/share/pixmaps/QSanguosha.png"
52 # Set Ownership to root:games
53 chown -R root:games "${pkgdir}/opt/qsanguosha"
54 chmod -R g+rw "${pkgdir}/opt/qsanguosha"