app-office/ledger: revbump to 3.1-r1
authorErik Mackdanz <stasibear@gentoo.org>
Tue, 10 Nov 2015 23:57:40 +0000 (17:57 -0600)
committerErik Mackdanz <stasibear@gentoo.org>
Tue, 10 Nov 2015 23:57:40 +0000 (17:57 -0600)
Adds IUSE="doc emacs".  Closing bug 564226

Package-Manager: portage-2.2.24

app-office/ledger/files/50ledger-gentoo-3.1.el [new file with mode: 0644]
app-office/ledger/ledger-3.1-r1.ebuild [new file with mode: 0644]

diff --git a/app-office/ledger/files/50ledger-gentoo-3.1.el b/app-office/ledger/files/50ledger-gentoo-3.1.el
new file mode 100644 (file)
index 0000000..1c2c5bd
--- /dev/null
@@ -0,0 +1,5 @@
+
+;;; app-office/ledger site-lisp configuration
+
+(add-to-list 'load-path "@SITELISP@")
+(autoload 'ledger-mode "ledger-mode" "A mode for editing ledger data files." t)
diff --git a/app-office/ledger/ledger-3.1-r1.ebuild b/app-office/ledger/ledger-3.1-r1.ebuild
new file mode 100644 (file)
index 0000000..c1714fd
--- /dev/null
@@ -0,0 +1,71 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit cmake-utils elisp-common
+
+DESCRIPTION="A double-entry accounting system with a command-line reporting interface"
+HOMEPAGE="http://ledger-cli.org/"
+SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+KEYWORDS="~amd64 ~x86"
+SLOT="0"
+IUSE="doc emacs"
+
+SITEFILE=50${PN}-gentoo-${PV}.el
+
+RDEPEND="
+       dev-libs/boost:=
+       dev-libs/gmp:0
+       dev-libs/mpfr:0
+       emacs? ( virtual/emacs )
+"
+DEPEND="${RDEPEND}
+       dev-libs/utfcpp
+       doc? ( sys-apps/texinfo )
+"
+
+DOCS=(README-1ST README.md)
+
+src_configure() {
+       local mycmakeargs=(
+               $(cmake-utils_use_build emacs EMACSLISP)
+               $(cmake-utils_use_build doc DOCS)
+               $(cmake-utils_use_build doc WEB_DOCS)
+               -DCMAKE_INSTALL_DOCDIR=/usr/share/doc/${PF}
+       )
+
+       cmake-utils_src_configure
+}
+
+src_compile() {
+       cmake-utils_src_compile
+
+       use doc && cmake-utils_src_make doc
+}
+
+src_install() {
+       enable_cmake-utils_src_install
+
+       use emacs && elisp-site-file-install "${FILESDIR}/${SITEFILE}"
+}
+
+pkg_postinst() {
+       use emacs && elisp-site-regen
+
+       einfo
+       einfo "Since version 3, vim support is released separately."
+       einfo "See https://github.com/ledger/vim-ledger"
+       einfo
+}
+
+pkg_postrm() {
+       use emacs && elisp-site-regen
+}
+
+# rainy day TODO:
+# - IUSE python
+# - IUSE test