1 # Maintainer: Andrea Fagiani <andfagiani_at_gmail_dot_com>
6 pkgdesc="Brings Eclipse functionality to Vim"
7 url="http://eclim.org/"
10 depends=('vim' 'eclipse')
11 makedepends=('apache-ant' 'python2-sphinx')
12 optdepends=('eclipse-pdt: Eclipse PHP Development Tools support'
13 'eclipse-cdt: Eclipse C/C++ Plugin support'
14 'eclipse-dltk-core: Eclipse Dynamic Languagues Toolkit support'
15 'eclipse-dltk-ruby: Eclipse Ruby support'
16 'eclipse-wtp-wst: Eclipse Web Developer Tools support')
17 conflicts=('eclim-git')
18 install=$pkgname.install
19 source=("http://downloads.sourceforge.net/project/$pkgname/$pkgname/$pkgver/${pkgname}_$pkgver.tar.gz"
22 md5sums=('35882a173e8d340ceee527165cf359f8'
23 '4b409b255947af738652f9db20a437ae'
24 '82ad75037bef68979aedc4f08a121a10')
26 cd $srcdir/${pkgname}_$pkgver
28 patch -Np1 -i $srcdir/resources.patch
29 patch -Np1 -i $srcdir/sphinx.patch
32 # jdt, ant and maven only require eclipse so they can be enabled without worries
33 # might want to edit the _plugins array with those that suit your needs
34 # options are : jdt, ant, maven, pdt, cdt, wst, dltk, dltkruby
35 _plugins='jdt,ant,maven'
37 # Eventually enabling additional plugins, be sure to comment this if you're defining your own
38 _plugins=$(pacman -Qs eclipse- | sed -n 's/.*\(pdt\|cdt\|wst\|dltk\(-ruby\)*\).*/\1/p' | tr '\n-' ',\0')$_plugins
40 # Get the ANT_HOME environment variable
41 source /etc/profile.d/apache-ant.sh
43 # Build (necessary, we need to build with the correct environment variables
44 mkdir -p $pkgdir/usr/share/eclipse
45 mkdir -p $pkgdir/usr/share/vim/vimfiles
47 chmod +x src/nailgun/configure bin/sphinx
49 # recompiling nailgun to make sure the executable is compliant with our architecture
55 ant -Declipse.home=/usr/share/eclipse \
56 -Dvim.files=/usr/share/vim/vimfiles \
60 ant -Declipse.home=$pkgdir/usr/share/eclipse \
61 -Dvim.files=$pkgdir/usr/share/vim/vimfiles \
65 ant -Declipse.home=/usr/share/eclipse -Dvim.files=$pkgdir/usr/share/vim/vimfiles docs vimdocs
68 mkdir -p $pkgdir/usr/share/doc/
69 cp -r build/doc/site $pkgdir/usr/share/doc/eclim
72 sed -i -e "s|$pkgdir||g" $pkgdir/usr/share/vim/vimfiles/eclim/plugin/eclim.vim
74 # delete Windows stuff
75 for i in $(find $pkgdir -regex ".*bat\|.*cmd\|.*exe"); do rm -f $i ; done