Created attachment 208831 [details] Port patch This is to update the net/yggdrasil port to the latest released version.
Created attachment 208832 [details] Patch file
Created attachment 208833 [details] Patch file
(In reply to Neil Alexander from comment #2) Hi, Thanks for the update, there are a few issues that need fixing: (1) It doesn't pass portlint checks: $ portlint -AC FATAL: Makefile: [3]: use a tab (not space) after a variable name FATAL: Makefile: [4]: use a tab (not space) after a variable name FATAL: Makefile: [5]: use a tab (not space) after a variable name FATAL: Makefile: [6]: use a tab (not space) after a variable name FATAL: Makefile: [7]: use a tab (not space) after a variable name FATAL: Makefile: [9]: use a tab (not space) after a variable name FATAL: Makefile: [10]: use a tab (not space) after a variable name FATAL: Makefile: [12]: use a tab (not space) after a variable name FATAL: Makefile: [13]: use a tab (not space) after a variable name FATAL: Makefile: [15]: use a tab (not space) after a variable name FATAL: Makefile: [17]: use a tab (not space) after a variable name FATAL: Makefile: [18]: use a tab (not space) after a variable name FATAL: Makefile: [19]: use a tab (not space) after a variable name FATAL: Makefile: [20]: use a tab (not space) after a variable name FATAL: Makefile: [21]: use a tab (not space) after a variable name FATAL: Makefile: [37]: use a tab (not space) after a variable name WARN: Makefile: [38]: use tab (not space) to make indentation WARN: Makefile: [39]: use a tab (not space) after a variable name FATAL: Makefile: [41]: use a tab (not space) after a variable name 17 fatal errors and 2 warnings found. (2) Please remove MASTER_SITES/GH_TAGNAME and put back DISTVERSIONPREFIX=v. (3) Remove BUILD_DEPENDS=go>=1.13:lang/go, Go ports should use USES=go (USES=go:modules in this case [1]) (4) Remove MAKE_ENV+=GOFLAGS=-mod=vendor, go.mk already takes care of that. -- [1] https://www.freebsd.org/doc/en/books/porters-handbook/book.html#using-go
Created attachment 208841 [details] Patch file Updated the patch based on Dmitri's feedback.
Hi Dmitri, Thanks for the feedback - I am still quite new to creating ports. I've addressed your points, although I have left in the BUILD_DEPENDS=go>=1.13:lang/go line as we do have a hard requirement on Go 1.13 - our build will fail on earlier Go versions as we are referring to new built-in packages that did not exist before this version. Please let me know if there's a more idiomatic way to express this in the Makefile. I hope the new patch is acceptable.
(In reply to Neil Alexander from comment #5) Hi Neil, Ports doesn't provide anything older than go1.13 so BUILD_DEPENDS=go>=1.13 is always satisfied. I think the most straightforward/idiomatic way to enforce go >= 1.13 requirement would be to use build tags in source ("// +build go1.13"). Another problem with explicit BUILD_DEPENDS=go is that it hardcodes dependency on lang/go and prevents testing ports with lang/go-devel.
Created attachment 208854 [details] Patch file
Hi Dmitri, Thanks for the explanation. I've updated the patch again to remove BUILD_DEPENDS - I'm happy if the ports tree contains only Go 1.13 or later.
A commit references this bug: Author: dmgk Date: Mon Nov 4 13:12:12 UTC 2019 New revision: 516640 URL: https://svnweb.freebsd.org/changeset/ports/516640 Log: net/yggdrasil: Update to 0.3.11 - Remove custom build targets while here Changes: https://github.com/yggdrasil-network/yggdrasil-go/releases/tag/v0.3.11 PR: 241695 Submitted by: Neil Alexander <freebsd@neilalexander.dev> (maintainer) Approved by: tz (mentor, implicit) Changes: head/net/yggdrasil/Makefile head/net/yggdrasil/distinfo
Committed with some changes, thanks!