summaryrefslogtreecommitdiff
path: root/sci-mathematics/proverif/proverif-2.04-r1.ebuild
blob: a70d69a747de9d1a983e60e4e73d9a481066c0f1 (plain)
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
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

inherit edo elisp-common findlib

DESCRIPTION="Cryptographic protocol verifier in the formal model"
HOMEPAGE="https://bblanche.gitlabpages.inria.fr/proverif/
	https://gitlab.inria.fr/bblanche/proverif/"

if [[ "${PV}" == *9999* ]] ; then
	inherit git-r3

	EGIT_REPO_URI="https://gitlab.inria.fr/bblanche/${PN}.git"
	S="${WORKDIR}/${P}/${PN}"
else
	SRC_URI="https://gitlab.inria.fr/bblanche/${PN}/-/archive/v${PV}/${PN}-v${PV}.tar.bz2"
	S="${WORKDIR}/${PN}-v${PV}/${PN}"

	KEYWORDS="~amd64 ~x86"
fi

LICENSE="GPL-2+"
SLOT="0"
IUSE="emacs"

RDEPEND="
	dev-lang/ocaml:=[ocamlopt]
	emacs? ( >=app-editors/emacs-25:* )
"
DEPEND="
	${RDEPEND}
"

DOCS=( CHANGES README docs/dev docs/manual )
SITEFILE="50${PN}-gentoo.el"

src_compile() {
	edob sh ./build -nointeract

	if use emacs ; then
		cd "${S}/emacs" || die

		elisp-compile *.el
	fi
}

src_test() {
	edob sh ./test
}

src_install() {
	findlib_src_preinst

	exeinto /usr/bin
	doexe proverif
	doexe proveriftotex

	if use emacs ; then
		elisp-install "${PN}" "${S}/emacs"/*.el{,c}
		elisp-site-file-install "${FILESDIR}/${SITEFILE}"
	fi

	einstalldocs
}