1 |
commit: 1a9dcd920eaa88e57204e966c2779c9eac98495d |
2 |
Author: Marek Szuba <marecki <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Nov 7 10:49:31 2019 +0000 |
4 |
Commit: Marek Szuba <marecki <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Nov 7 10:52:00 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1a9dcd92 |
7 |
|
8 |
net-p2p/syncthing-1.3.1: switch to go-module.eclass |
9 |
|
10 |
Should hopefully resolve problems with go-1.13 in the network sandbox |
11 |
observed by some users. |
12 |
|
13 |
Bug: https://bugs.gentoo.org/693922 |
14 |
Package-Manager: Portage-2.3.76, Repoman-2.3.16 |
15 |
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org> |
16 |
|
17 |
net-p2p/syncthing/syncthing-1.3.1.ebuild | 23 ++++++++--------------- |
18 |
1 file changed, 8 insertions(+), 15 deletions(-) |
19 |
|
20 |
diff --git a/net-p2p/syncthing/syncthing-1.3.1.ebuild b/net-p2p/syncthing/syncthing-1.3.1.ebuild |
21 |
index 25a84914f7b..8f0e558ef16 100644 |
22 |
--- a/net-p2p/syncthing/syncthing-1.3.1.ebuild |
23 |
+++ b/net-p2p/syncthing/syncthing-1.3.1.ebuild |
24 |
@@ -3,8 +3,6 @@ |
25 |
|
26 |
EAPI=7 |
27 |
|
28 |
-EGO_PN="github.com/${PN}/${PN}" |
29 |
- |
30 |
EGO_VENDOR=( |
31 |
"github.com/AudriusButkevicius/go-nat-pmp 452c97607362b2ab5a7839b8d1704f0396b640ca" |
32 |
"github.com/AudriusButkevicius/pfilter 0.0.5" |
33 |
@@ -67,12 +65,12 @@ EGO_VENDOR=( |
34 |
"github.com/prometheus/procfs v0.0.4" |
35 |
) |
36 |
|
37 |
-inherit golang-vcs-snapshot systemd xdg-utils |
38 |
+inherit go-module systemd xdg-utils |
39 |
|
40 |
DESCRIPTION="Open Source Continuous File Synchronization" |
41 |
HOMEPAGE="https://syncthing.net" |
42 |
-SRC_URI="https://${EGO_PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz |
43 |
- ${EGO_VENDOR_URI}" |
44 |
+SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz |
45 |
+ $(go-module_vendor_uris)" |
46 |
|
47 |
LICENSE="Apache-2.0 BSD BSD-2 ISC MIT MPL-2.0 Unlicense" |
48 |
SLOT="0" |
49 |
@@ -96,30 +94,26 @@ src_prepare() { |
50 |
default |
51 |
sed -i \ |
52 |
's|^ExecStart=.*|ExecStart=/usr/libexec/syncthing/strelaysrv|' \ |
53 |
- src/${EGO_PN}/cmd/strelaysrv/etc/linux-systemd/strelaysrv.service \ |
54 |
+ cmd/strelaysrv/etc/linux-systemd/strelaysrv.service \ |
55 |
|| die |
56 |
|
57 |
# As of 1.3.1, stupgrades fails to compile. This command was not present |
58 |
# in releases older than 1.3.0, is not compiled in by default (USE=tools |
59 |
# must be set) an in any case we do not really need this, therefore just |
60 |
# get rid of the offending code until upstream has fixed it. |
61 |
- rm -rf src/${EGO_PN}/cmd/stupgrades |
62 |
+ rm -rf cmd/stupgrades |
63 |
} |
64 |
|
65 |
src_compile() { |
66 |
- export GOPATH="${S}:$(get_golibdir_gopath)" |
67 |
- cd src/${EGO_PN} || die |
68 |
go run build.go -version "v${PV}" -no-upgrade install \ |
69 |
$(usex tools "all" "") || die "build failed" |
70 |
} |
71 |
|
72 |
src_test() { |
73 |
- cd src/${EGO_PN} || die |
74 |
go run build.go test || die "test failed" |
75 |
} |
76 |
|
77 |
src_install() { |
78 |
- pushd src/${EGO_PN} >& /dev/null || die |
79 |
doman man/*.[157] |
80 |
einstalldocs |
81 |
|
82 |
@@ -131,11 +125,10 @@ src_install() { |
83 |
[[ "${exe}" == "bin/syncthing" ]] || doexe "${exe}" |
84 |
done |
85 |
fi |
86 |
- popd >& /dev/null || die |
87 |
|
88 |
# openrc and systemd service files |
89 |
- systemd_dounit src/${EGO_PN}/etc/linux-systemd/system/${PN}{@,-resume}.service |
90 |
- systemd_douserunit src/${EGO_PN}/etc/linux-systemd/user/${PN}.service |
91 |
+ systemd_dounit etc/linux-systemd/system/${PN}{@,-resume}.service |
92 |
+ systemd_douserunit etc/linux-systemd/user/${PN}.service |
93 |
newconfd "${FILESDIR}/${PN}.confd" ${PN} |
94 |
newinitd "${FILESDIR}/${PN}.initd" ${PN} |
95 |
|
96 |
@@ -151,7 +144,7 @@ src_install() { |
97 |
newconfd "${FILESDIR}/stdiscosrv.confd" stdiscosrv |
98 |
newinitd "${FILESDIR}/stdiscosrv.initd" stdiscosrv |
99 |
|
100 |
- systemd_dounit src/${EGO_PN}/cmd/strelaysrv/etc/linux-systemd/strelaysrv.service |
101 |
+ systemd_dounit cmd/strelaysrv/etc/linux-systemd/strelaysrv.service |
102 |
newconfd "${FILESDIR}/strelaysrv.confd" strelaysrv |
103 |
newinitd "${FILESDIR}/strelaysrv.initd" strelaysrv |