updated on Tue Jan 10 04:01:21 UTC 2012
[aur-mirror.git] / textadept / PKGBUILD
blobe23a870f82ad733292bd8d2aad4e1266f8aed0e6
1 # Maintainer: M Rawash <mrawash@gmail.com>
3 pkgname=textadept
4 pkgver=4.2
5 pkgrel=1
6 pkgdesc="A ridiculously fast and extensible text editor"
7 arch=('i686' 'x86_64')
8 url="http://code.google.com/p/textadept"
9 license=('MIT')
10 depends=('gtk2' 'lua')
11 optdepends=('ctags: auto-completion')
12 makedepends=('unzip')
13 install=${pkgname}.install
14 source=(http://textadept.googlecode.com/files/${pkgname}_${pkgver}.src.zip
15         ${pkgname}.desktop
16         pkgbuild.lua)
17 md5sums=('309a35b106dc27d1803b827ab1e168ba'
18          '16352a54ad59c89a78fded6d140107a6'
19          'f0b2f243460b231dbeb6f547d8c1822b')
20 build() {
21   cd "$srcdir/${pkgname}_${pkgver}"
23   cd src/scintilla/gtk
24   make || return 1
26   cd ../../
27   sed -i 's|/usr/local/|/usr/|' lua/include/luaconf.h
28   make  || return 1
30   #there's no target install - installing manually
31   mkdir -p ${pkgdir}/usr/{bin,share}
32   cp -r  ${srcdir}/${pkgname}_${pkgver} ${pkgdir}/usr/share/${pkgname}
33   ln -sf /usr/share/${pkgname}/textadept ${pkgdir}/usr/bin/textadept
34   install -Dm644 ../LICENSE ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
36   #now clean this mess
37   rm -r ${pkgdir}/usr/share/${pkgname}/{src,LICENSE}
39   #make ta pkgbuild friendly
40   install -Dm644 $srcdir/pkgbuild.lua $pkgdir/usr/share/${pkgname}/lexers/pkgbuild.lua
41   echo -e "\n% PKGBUILD\nPKGBUILD pkgbuild\ninstall pkgbuild" >> \
42         $pkgdir/usr/share/${pkgname}/modules/textadept/mime_types.conf
44   #freedesktop.org stuff
45   install -Dm644 ${pkgdir}/usr/share/${pkgname}/core/images/ta_128x128.png \
46                         ${pkgdir}/usr/share/pixmaps/${pkgname}.png
47   install -Dm644 ${srcdir}/${pkgname}.desktop \
48                         ${pkgdir}/usr/share/applications/${pkgname}.desktop