summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author4ur3l13n <aurelien@hackers.camp>2015-11-07 16:44:57 +0100
committer4ur3l13n <aurelien@hackers.camp>2015-11-07 16:44:57 +0100
commit4309c3414574d7b2d691c6d02e3c7be4d4e68207 (patch)
tree81dd424b3870161374cb3213908d037f9cf006cf
parentfc1d262bb203e5d206af504c13c24469726d832c (diff)
downloadabslibre-4309c3414574d7b2d691c6d02e3c7be4d4e68207.tar.gz
abslibre-4309c3414574d7b2d691c6d02e3c7be4d4e68207.tar.bz2
abslibre-4309c3414574d7b2d691c6d02e3c7be4d4e68207.zip
eclim vim eclipse functionality
-rw-r--r--pcr/eclim/PKGBUILD84
-rw-r--r--pcr/eclim/eclim.install18
2 files changed, 102 insertions, 0 deletions
diff --git a/pcr/eclim/PKGBUILD b/pcr/eclim/PKGBUILD
new file mode 100644
index 000000000..4c4e7d10f
--- /dev/null
+++ b/pcr/eclim/PKGBUILD
@@ -0,0 +1,84 @@
+# Maintainer: Aurélien DESBRIÈRES <aurelien@hackers.camp>
+# Contributor: Andrea Fagiani <andfagiani_at_gmail_dot_com>
+
+pkgname=eclim
+pkgver=2.5.0
+pkgrel=1
+pkgdesc="Brings Eclipse functionality to Vim"
+url="http://eclim.org/"
+license=('GPL3')
+arch=(i686 x86_64)
+depends=('vim' 'eclipse')
+makedepends=('apache-ant' 'python2-sphinx')
+optdepends=('eclipse-pdt: Eclipse PHP Development Tools support'
+ 'eclipse-cdt: Eclipse C/C++ Plugin support'
+ 'eclipse-dltk-core: Eclipse Dynamic Languagues Toolkit support'
+ 'eclipse-dltk-ruby: Eclipse Ruby support'
+ 'eclipse-wtp: Eclipse Web Developer Tools support')
+conflicts=('eclim-git')
+install=$pkgname.install
+source=("http://downloads.sourceforge.net/project/$pkgname/$pkgname/$pkgver/${pkgname}_$pkgver.tar.gz")
+
+prepare() {
+ cd $srcdir/${pkgname}_$pkgver
+
+ # fix build, thanks to mikezackles
+ sed -e "s/'sphinx-build'/'sphinx-build2'/g" \
+ -e 's|${user.home}/\.|${vim.files}/|g' \
+ -e "s|File(getVariable('eclipse')|File('/usr/lib/eclipse/'|g" \
+ -e '68,88d' \
+ -i ant/build.gant
+
+ # Get the ANT_HOME environment variable
+ source /etc/profile.d/apache-ant.sh
+
+ chmod +x org.eclim/nailgun/configure bin/sphinx
+}
+
+build() {
+ cd $srcdir/${pkgname}_$pkgver
+
+ # recompiling nailgun to make sure the executable is compliant with our architecture
+ cd org.eclim/nailgun
+ ./configure
+ make
+
+ cd ../..
+
+ ant -Declipse.home=/usr/lib/eclipse \
+ -Dvim.files=/usr/share/vim/vimfiles \
+ build
+}
+
+package() {
+ cd $srcdir/${pkgname}_$pkgver
+
+ mkdir -p $pkgdir/usr/lib/eclipse
+ mkdir -p $pkgdir/usr/share/vim/vimfiles
+
+ ant -Declipse.home=/usr/lib/eclipse \
+ -Dvim.files=$pkgdir/usr/share/vim/vimfiles \
+ docs vimdocs
+
+ ant -Declipse.home=$pkgdir/usr/lib/eclipse \
+ -Dvim.files=$pkgdir/usr/share/vim/vimfiles \
+ deploy
+
+ # copy eclim docs
+ mkdir -p $pkgdir/usr/share/doc/
+ cp -r build/doc/site $pkgdir/usr/share/doc/eclim
+
+ # fix eclim paths
+ sed -e "s|$pkgdir||g" \
+ -i $pkgdir/usr/share/vim/vimfiles/eclim/plugin/eclim.vim \
+ -i $pkgdir/usr/lib/eclipse/plugins/org.eclim_$pkgver/bin/eclimd \
+ -i $pkgdir/usr/lib/eclipse/plugins/org.eclim_$pkgver/plugin.properties
+
+ # delete doctrees
+ rm -fr $pkgdir/usr/share/doc/eclim/.doctrees
+
+ # delete Windows stuff
+ for i in $(find $pkgdir -regex ".*bat\|.*cmd\|.*exe"); do rm -f $i ; done
+
+ rm $pkgdir/usr/lib/eclipse/plugins/org.eclim_${pkgver}/nailgun/config.status
+}
diff --git a/pcr/eclim/eclim.install b/pcr/eclim/eclim.install
new file mode 100644
index 000000000..72dc02205
--- /dev/null
+++ b/pcr/eclim/eclim.install
@@ -0,0 +1,18 @@
+post_install() {
+ echo "
+ >>> Copy the /usr/share/vim/vimfiles/eclim/resources
+ >>> directory to ~/.eclim/resources
+ "
+
+ # rebuild the vim documentation tags
+ vim -e -u NONE --cmd "helptags /usr/share/vim/vimfiles/eclim/doc/" --cmd quit
+}
+post_upgrade() {
+ echo "
+ >>> Copy the /usr/share/vim/vimfiles/eclim/resources
+ >>> directory to ~/.eclim/resources
+ "
+}
+post_remove() {
+ /bin/true
+}