add local overlay

This commit is contained in:
Anton Schubert 2016-05-08 14:09:54 +02:00
commit 4883c62e9a
68 changed files with 2719 additions and 0 deletions

2
dev-util/racer/Manifest Normal file
View file

@ -0,0 +1,2 @@
DIST racer-v1.1.0.tar.gz 118276 SHA256 f969e66d5119f544347e9f9424e83d739eef0c75811fa1a5c77e58df621e066d SHA512 880bbd028eac665a6c43ef9f494e1d23d726dd196ceae9bfa1d9896f6af86def1bbba7c3b4bed6079f0089a01b26c76a703206dc6f33a6e99c79b2344af85bef WHIRLPOOL 707adb064451ec7b4d3ae081675273dbd72cfd554a9b0e0e0518fa98848e76534b21a4185b84968a0b76f551278fef3ba96d77a49b70da0855e42fca097b8776
EBUILD racer-1.1.0.ebuild 1769 SHA256 dfe190be28f0c9109b5ace8ccea7c31c0338e6eb29621411a096ed9a51d9d477 SHA512 2c682c8d8a62f8a42c3c5f79989b42d6d9bbebf2f8d6447dd4020198e998e1a5227325ffe05b2c07cdd95f9651ae267b147a8040dbee0f25336a0d9091977245 WHIRLPOOL 4e73f22e887849f3a2aed21179bb31eb82ad4eb4a4a343ba84374d79e0d83f1c8b342979d6ac8ec89a99e0416b48795d5e3f70caa79b40f535468ad7fdb57f11

View file

@ -0,0 +1,68 @@
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
EAPI=5
inherit eutils elisp-common
DESCRIPTION="Rust Code Completion utility "
HOMEPAGE="https://github.com/phildawes/racer"
SRC_URI="https://github.com/phildawes/racer/archive/v${PV}.tar.gz -> ${PN}-v${PV}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
IUSE="emacs vim"
COMMON_DEPEND="virtual/rust:*
emacs? (
app-emacs/company-mode[ropemacs]
app-emacs/rust-mode
virtual/emacs )
vim? ( || ( app-editors/vim app-editors/gvim ) )"
DEPEND="${COMMON_DEPEND}
dev-util/cargo"
RDEPEND="${COMMON_DEPEND}"
src_compile() {
cargo build --release
}
src_install() {
dobin target/release/racer
if use emacs; then
elisp-install ${PN} editors/racer.el
elisp-site-file-install "${FILESDIR}/50${PN}-gentoo.el"
fi
if use vim; then
insinto /usr/share/vim/vimfiles/plugin/
sed -i 's|\(g:racer_cmd = \).*|\1"/usr/bin/racer"|' plugin/racer.vim
doins plugin/racer.vim
fi
}
pkg_postinst() {
elog "You most probably should fetch rust sources for best expirience."
elog "Racer will look for sources in path pointed by RUST_SRC_PATH"
elog "environment variable. You can use"
elog "% export RUST_SRC_PATH=<path to>/rust/src."
elog
if use emacs; then
elog "You should use '(setq racer-rust-src-path \"<path-to>/rust/src/\")'"
elog "for emacs plugin to be able to find rust sources for racer."
elog
elisp-site-regen
fi
if use vim; then
elog "For vim you can use 'let \$RUST_SRC_PATH=\"<path-to>/rust/src/\"'"
elog "if you don't want to use environment variable"
elog "You also can use \"set hidden\" or else your buffer will be"
elog "unloaded on every goto-definition"
fi
}
pkg_postrm() {
use emacs && elisp-site-regen
}