forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ledger-3.1-r1.ebuild
71 lines (54 loc) · 1.32 KB
/
ledger-3.1-r1.ebuild
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# Copyright 1999-2016 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-1.58:=
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