1 # Contributor: A. Fluteaux <sigma_g@melix.net>
5 pkgdesc="GIT version of mudlet"
7 url="http://sourceforge.net/projects/mudlet/"
9 depends=('lua' 'qscintilla' 'qt' 'yajl>=2' 'luasql-sqlite3' 'luafilesystem' 'lrexlib-pcre' 'luazip')
10 makedepends=('cmake' 'boost')
12 source=('http://vrac.kadarniad.fr/lua_yajl2.c')
13 md5sums=('c65ba1cc397fc987ae7956989ede172b')
14 _gitroot="git://mudlet.git.sourceforge.net/gitroot/mudlet/mudlet"
19 msg "Connecting to GIT server...."
21 if [ -d $_gitname ] ; then
22 cd $_gitname && git pull origin
23 msg "The local files are updated."
25 git clone $_gitroot $_gitname
28 rm -rf "$srcdir/$_gitname-build"
29 git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
30 cd "$srcdir/$_gitname-build/src"
32 #Patches for Arch with yajl2 and hunspell1.3
33 cp $srcdir/lua_yajl2.c .
34 for i in *.{cpp,h} ; do sed -i 's/#include <phonon>/#include <phonon\/MediaObject>\n#include <phonon\/AudioOutput>/' $i ; done
35 sed -i 's/lua_yajl1.c/lua_yajl2.c/' TLuaInterpreter.cpp
36 sed -i 's/-lhunspell/-lhunspell-1.3/' src.pro
37 sed -i 's/lua_yajl1.c/lua_yajl2.c/' src.pro
39 # This ... is really ugly, but after 5+ hours working on it, I am bored
40 sed -i 's#QString path = \"mudlet-lua/lua/LuaGlobal.lua\";#QString path = \"/usr/local/share/mudlet/LuaGlobal.lua\";#' TLuaInterpreter.cpp
49 cd $srcdir/$_gitname-build/src
50 make INSTALL_ROOT=${pkgdir} install
51 #install -D ${srcdir}/$_gitname-build/src/mudlet ${pkgdir}/usr/bin/mudlet || return 1