From owner-svn-ports-all@freebsd.org Tue Aug 13 17:23:16 2019 Return-Path: Delivered-To: svn-ports-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id C60D1B6A71; Tue, 13 Aug 2019 17:23:16 +0000 (UTC) (envelope-from tobik@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 467KLD4rbZz484H; Tue, 13 Aug 2019 17:23:16 +0000 (UTC) (envelope-from tobik@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 895611ACE1; Tue, 13 Aug 2019 17:23:16 +0000 (UTC) (envelope-from tobik@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id x7DHNGog082308; Tue, 13 Aug 2019 17:23:16 GMT (envelope-from tobik@FreeBSD.org) Received: (from tobik@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id x7DHNGo0082307; Tue, 13 Aug 2019 17:23:16 GMT (envelope-from tobik@FreeBSD.org) Message-Id: <201908131723.x7DHNGo0082307@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: tobik set sender to tobik@FreeBSD.org using -f From: Tobias Kortkamp Date: Tue, 13 Aug 2019 17:23:16 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r508838 - head/Mk/Uses X-SVN-Group: ports-head X-SVN-Commit-Author: tobik X-SVN-Commit-Paths: head/Mk/Uses X-SVN-Commit-Revision: 508838 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Aug 2019 17:23:16 -0000 Author: tobik Date: Tue Aug 13 17:23:16 2019 New Revision: 508838 URL: https://svnweb.freebsd.org/changeset/ports/508838 Log: Mk/Uses/go.mk: Add gomod-vendor helper target For USES=go:modules ports it simplifies generating GH_TUPLE by calling modules2tuple in the right directory etc. Submitted by: Dmitri Goutnik (maintainer) Differential Revision: https://reviews.freebsd.org/D21246 Modified: head/Mk/Uses/go.mk Modified: head/Mk/Uses/go.mk ============================================================================== --- head/Mk/Uses/go.mk Tue Aug 13 16:03:11 2019 (r508837) +++ head/Mk/Uses/go.mk Tue Aug 13 17:23:16 2019 (r508838) @@ -126,4 +126,17 @@ do-install: .endfor .endif +# Helper targets for port maintainers + +.if ${go_ARGS:Mmodules} +_MODULES2TUPLE_CMD= modules2tuple +gomod-vendor: patch + @if type ${_MODULES2TUPLE_CMD} > /dev/null 2>&1; then \ + cd ${WRKSRC}; ${GO_CMD} mod vendor; \ + [ -r vendor/modules.txt ] && ${_MODULES2TUPLE_CMD} vendor/modules.txt; \ + else \ + ${ECHO_MSG} "===> Please install \"ports-mgmt/modules2tuple\""; \ + fi +.endif + .endif # defined(_POSTMKINCLUDED) && !defined(_INCLUDE_USES_GO_POST_MK)