dev-python/numpydoc: arm64 keyworded (bug #721130)
[gentoo.git] / app-crypt / keybase / keybase-4.5.0.ebuild
1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5
6 inherit golang-build systemd
7
8 DESCRIPTION="Client for keybase.io"
9 HOMEPAGE="https://keybase.io/"
10 SRC_URI="https://github.com/keybase/client/archive/v${PV}.tar.gz -> ${P}.tar.gz"
11
12 LICENSE="Apache-2.0 BSD BSD-2 LGPL-3 MIT MPL-2.0"
13 SLOT="0"
14 KEYWORDS="~amd64 ~x86"
15 IUSE=""
16
17 DEPEND=""
18 RDEPEND="app-crypt/gnupg"
19
20 src_unpack() {
21         unpack "${P}.tar.gz"
22         ln -vs "client-${PV}" "${P}" || die
23         mkdir -vp "${S}/src/github.com/keybase" || die
24         ln -vs "${S}" "${S}/src/github.com/keybase/client" || die
25 }
26
27 src_compile() {
28         EGO_PN="github.com/keybase/client/go/keybase" \
29                 EGO_BUILD_FLAGS="-tags production -o ${T}/keybase" \
30                 golang-build_src_compile
31 }
32
33 src_test() {
34         EGO_PN="github.com/keybase/client/go/keybase" \
35                 golang-build_src_test
36 }
37
38 src_install() {
39         dobin "${T}/keybase"
40         dobin "${S}/packaging/linux/run_keybase"
41         systemd_douserunit "${S}/packaging/linux/systemd/keybase.service"
42         dodir "/opt/keybase"
43         insinto "/opt/keybase"
44         doins "${S}/packaging/linux/crypto_squirrel.txt"
45 }
46
47 pkg_postinst() {
48         elog "Start/Restart keybase: run_keybase"
49         elog "Run the service:       keybase service"
50         elog "Run the client:        keybase login"
51         ewarn "Note that the user keybasehelper is obsolete and can be removed"
52 }