aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBratishkaErik <bratishkaerik@getgoogleoff.me>2022-03-26 21:28:19 +0600
committerBratishkaErik <bratishkaerik@getgoogleoff.me>2022-03-26 21:28:19 +0600
commit3b818583939050b64fa2c995ee795ef85fbfa779 (patch)
treeb4516b334b7ddea83cd03f38f83a0e2049fc82b5
parentnet-p2p/yggdrasil-go: add new version (diff)
downloadguru-3b818583.tar.gz
guru-3b818583.tar.bz2
guru-3b818583.zip
net-p2p/yggdrasil-go: add 9999 version
Package-Manager: Portage-3.0.30, Repoman-3.0.3 Signed-off-by: BratishkaErik <bratishkaerik@getgoogleoff.me>
-rw-r--r--net-p2p/yggdrasil-go/yggdrasil-go-9999.ebuild50
1 files changed, 50 insertions, 0 deletions
diff --git a/net-p2p/yggdrasil-go/yggdrasil-go-9999.ebuild b/net-p2p/yggdrasil-go/yggdrasil-go-9999.ebuild
new file mode 100644
index 000000000..d803f16d4
--- /dev/null
+++ b/net-p2p/yggdrasil-go/yggdrasil-go-9999.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit go-module linux-info systemd git-r3
+
+EGIT_REPO_URI="https://github.com/yggdrasil-network/yggdrasil-go"
+
+DESCRIPTION="An experiment in scalable routing as an encrypted IPv6 overlay network"
+HOMEPAGE="https://yggdrasil-network.github.io/"
+DOCS=( README.md )
+
+LICENSE="LGPL-3 MIT Apache-2.0 BSD ZLIB"
+SLOT="0"
+KEYWORDS=""
+
+DEPEND="
+ acct-user/yggdrasil
+ acct-group/yggdrasil
+"
+
+BDEPEND=">=dev-lang/go-1.16.0"
+
+pkg_setup() {
+ linux-info_pkg_setup
+ if ! linux_config_exists; then
+ eerror "Unable to check your kernel for TUN support"
+ else
+ CONFIG_CHECK="~TUN"
+ ERROR_TUN="Your kernel lacks TUN support."
+ fi
+}
+
+src_unpack() {
+ git-r3_src_unpack
+ go-module_live_vendor
+}
+
+src_compile() {
+ GOFLAGS="-trimpath -buildmode=pie -mod=readonly" \
+ ./build -l "-linkmode external -extldflags \"${LDFLAGS}\""
+}
+
+src_install() {
+ dobin {yggdrasil,yggdrasilctl}
+ systemd_dounit "contrib/systemd/yggdrasil.service"
+ systemd_dounit "contrib/systemd/yggdrasil-default-config.service"
+ doinitd "contrib/openrc/yggdrasil"
+}