pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Make wireguard-go work



Module Name:	pkgsrc-wip
Committed By:	Jonathan Schleifer <js%nil.im@localhost>
Pushed By:	js
Date:		Fri Sep 18 23:20:05 2020 +0200
Changeset:	71d5ed6a37175813aacb74c15b69f6aa210fa31c

Modified Files:
	wireguard-go/Makefile
	wireguard-go/distinfo
Added Files:
	wireguard-go/PLIST
	wireguard-go/patches/patch-rwcancel-select_default.go

Log Message:
Make wireguard-go work

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=71d5ed6a37175813aacb74c15b69f6aa210fa31c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 wireguard-go/Makefile                                 |  8 ++++++++
 wireguard-go/PLIST                                    |  2 ++
 wireguard-go/distinfo                                 |  1 +
 wireguard-go/patches/patch-rwcancel-select_default.go | 12 ++++++++++++
 4 files changed, 23 insertions(+)

diffs:
diff --git a/wireguard-go/Makefile b/wireguard-go/Makefile
index 6d9216e81d..8192bf4119 100644
--- a/wireguard-go/Makefile
+++ b/wireguard-go/Makefile
@@ -10,6 +10,14 @@ HOMEPAGE=	https://www.wireguard.com/
 COMMENT=	Implementation of WireGuard in Go
 LICENSE=	mit
 
+DEPENDS+=	wireguard-tools>=1.0.20200827:../../net/wireguard-tools
+
+INSTALLATION_DIRS+=	bin
+
+do-install:
+	${INSTALL_PROGRAM} ${WRKDIR}/.gopath/bin/wireguard \
+		${DESTDIR}${PREFIX}/bin/wireguard-go
+
 .include "go-modules.mk"
 
 .include "../../lang/go/go-module.mk"
diff --git a/wireguard-go/PLIST b/wireguard-go/PLIST
new file mode 100644
index 0000000000..aca6a1a9dd
--- /dev/null
+++ b/wireguard-go/PLIST
@@ -0,0 +1,2 @@
+@comment $NetBSD$
+bin/wireguard-go
diff --git a/wireguard-go/distinfo b/wireguard-go/distinfo
index 83bb4cde02..9110c48a8a 100644
--- a/wireguard-go/distinfo
+++ b/wireguard-go/distinfo
@@ -64,3 +64,4 @@ SHA1 (wireguard-go-0.0.20200320.tar.xz) = b76f871984b2689d7909eddf73d33a4c7b29c3
 RMD160 (wireguard-go-0.0.20200320.tar.xz) = acb5defeb676ae02cadada7be13d274b1fc4bc83
 SHA512 (wireguard-go-0.0.20200320.tar.xz) = e403b8747ec42f0e34eaedfa54f3fa5b09fb26cf0c7cf6c8f6c7f0edf2b7896f272860ee0561f8ecc051375e61a7b2b8ceb64e1f9a080f16f3c5ceb9e6c0f93b
 Size (wireguard-go-0.0.20200320.tar.xz) = 80556 bytes
+SHA1 (patch-rwcancel-select_default.go) = b873e0ca032103a32ca31b968f270bc532a2de0d
diff --git a/wireguard-go/patches/patch-rwcancel-select_default.go b/wireguard-go/patches/patch-rwcancel-select_default.go
new file mode 100644
index 0000000000..d467289796
--- /dev/null
+++ b/wireguard-go/patches/patch-rwcancel-select_default.go
@@ -0,0 +1,12 @@
+$NetBSD$
+
+--- rwcancel/select_default.go.orig	2020-03-20 18:00:53.000000000 +0000
++++ rwcancel/select_default.go
+@@ -10,5 +10,6 @@ package rwcancel
+ import "golang.org/x/sys/unix"
+ 
+ func unixSelect(nfd int, r *unix.FdSet, w *unix.FdSet, e *unix.FdSet, timeout *unix.Timeval) error {
+-	return unix.Select(nfd, r, w, e, timeout)
++	var _, err = unix.Select(nfd, r, w, e, timeout)
++	return err
+ }


Home | Main Index | Thread Index | Old Index