From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id B0E56138334 for ; Mon, 9 Sep 2019 22:57:32 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id AA553E0934; Mon, 9 Sep 2019 22:57:28 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 5F5AAE07A5 for ; Mon, 9 Sep 2019 22:57:28 +0000 (UTC) Received: from ws.localnet (unknown [100.42.98.196]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: gyakovlev) by smtp.gentoo.org (Postfix) with ESMTPSA id 2985B34AF49 for ; Mon, 9 Sep 2019 22:57:27 +0000 (UTC) From: Georgy Yakovlev To: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] rfc: go 1.13 and go modules Date: Mon, 09 Sep 2019 15:57:18 -0700 Message-ID: <1639276.kfM2EdqyNB@ws> In-Reply-To: <20190909214616.GA32528@whubbs1.dev.av1.gaikai.org> References: <20190909173418.GA30003@whubbs1.dev.av1.gaikai.org> <20190910083517.1877fd18@katipo2.lan> <20190909214616.GA32528@whubbs1.dev.av1.gaikai.org> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart1721420.bu9EmTzXfu"; micalg="pgp-sha256"; protocol="application/pgp-signature" X-Archives-Salt: 05e86819-d51f-49de-8bb0-ebeeb5acfb46 X-Archives-Hash: 38a4433f0b103b80cd2ebcd4b69b4df4 --nextPart1721420.bu9EmTzXfu Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" On Monday, September 9, 2019 2:46:16 PM PDT William Hubbs wrote: > On Tue, Sep 10, 2019 at 08:35:17AM +1200, Kent Fredric wrote: > > On Mon, 9 Sep 2019 12:34:18 -0500 > > > > William Hubbs wrote: > > > There is another option I want to try which is adding "go mod vendor" to > > > src_unpack for go packages. > > > > Is it infeasible to write a tool that you execute as a maintainer, that > > simulates what "go mod vendor" would do, but instead emits a list of > > entries for SRC_URI, and then have an eclass or something construct the > > vendor dir from those? > > > > That's what is available for rust stuff. > > I'm not sure how feasible something like that is. > > $ go list -m all > > will list the dependencies of a module, but that doesn't look like it > can be translated into src_uri format. > > You would basically have to parse go.mod exactly the way upstream does > it and come up with a way to download the correct versions of the > source. > > William check mail-client/aerc ebuild. I use "go list -m all" and manually format EGO_VENDOR string which will be translated into SRC_URI by eclass. tool is certainly possible and should be quite easy to implement. some manual editing will still be needed if dealing with forked packages/ repos, but looks pretty straightforward. This is very similar approach to cargo ebuilds and it supports offline installs, PM checksumming and does not require packaging every single go dependency as a package. --nextPart1721420.bu9EmTzXfu Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. Content-Transfer-Encoding: 7Bit -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEE3NQc5d2Nq7vhc9JNonLI8BUSnVIFAl122M4ACgkQonLI8BUS nVLSFA/9G8XZhQY/kTOgVbhvJHv8nCmCY+HBaqaDjFGFQWqniklYEmJGkLuHkaiw 2swtrDzqapcxCFvQiQThe78Kms3iZdObvXCMURwhT8MM1vxCPvg+6MP5PfIyklWh XQe331w1UNZEh86cEP1ZVNEaMeq6L66coR6zApQ7jYJU3JQyGTHQhYSUKI4BKF5A 9vIclvaRtm2WJ/gB7Wel7EwCv0Hb8vDnns77qtk1QfmqQ/CFWedM/5d0ZPeXmAOF w2MkrlzeABmySyuUVl7RaWDCt2Dh1N823f+IfoZUu5akY+qVXtS+YBhT2nkisz60 c6vjhIrpjj0cLFJhRufEwNttocF3yyyt8Iudhqz/AvuNy7At2Q0A3XdX1Be9RkPY cxlFQzXAld41XcDA1HLYLQT/LOCQE+GUdJcAngJeqsz0ZKx21tLvmWAc56/m7pfw 4ISjOVcvYvdmy9QrnHroqbSxr9xgvCke07+IT7Dtd5ItWaVSY5txQdIu05OH1QHe GpKGKcKNccWwNzIgnDBm4q+FARf76FvNDAE18bIkiylAEJIShnuv/Pkmyy5Y4+0V QmZkEaJGNXVgLSQqfobPMg84T5J9Qr1arDtqsR0l/XV3N7tDvSK4+5DVwiBUJR83 pP9rn4Ei2jriuKF/YiQ1ckM2x+ksjqsoYdqhWOKO4n83SmfC2nk= =Xv9w -----END PGP SIGNATURE----- --nextPart1721420.bu9EmTzXfu--