public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
From: Florian Schmaus <flow@gentoo.org>
To: gentoo-dev@lists.gentoo.org
Cc: William Hubbs <williamh@gentoo.org>, Florian Schmaus <flow@gentoo.org>
Subject: [gentoo-dev] [PATCH] go-module.eclass: undeprecate EGO_SUM
Date: Mon, 13 Jun 2022 09:44:11 +0200	[thread overview]
Message-ID: <20220613074411.341909-2-flow@gentoo.org> (raw)
In-Reply-To: <20220613074411.341909-1-flow@gentoo.org>

Following the gentoo-dev@ mailing list discussion [1], this
un-deprecates EGO_SUM.

1: https://archives.gentoo.org/gentoo-dev/message/1a64a8e7694c3ee11cd48a58a95f2faa

Signed-off-by: Florian Schmaus <flow@gentoo.org>
---
 eclass/go-module.eclass | 30 +++++++++++-------------------
 1 file changed, 11 insertions(+), 19 deletions(-)

diff --git a/eclass/go-module.eclass b/eclass/go-module.eclass
index a5dafb45cab8..2e0b7dc1726d 100644
--- a/eclass/go-module.eclass
+++ b/eclass/go-module.eclass
@@ -25,7 +25,9 @@
 #
 # If the software has a directory named vendor in its
 # top level directory, the only thing you need to do is inherit the
-# eclass. If it doesn't, you need to also create a dependency tarball and
+# eclass. If it doesn't, then you either 1) populate EGO_SUM in the ebuild and
+# call go-module_set_globals as discussed below or 2) you need to create a
+# dependency tarball and
 # host it somewhere, for example in your dev space.
 #
 # Here is an example of how to create a dependency tarball.
@@ -52,9 +54,14 @@
 #
 # inherit go-module
 #
+# EGO_SUM=(
+#   "github.com/aybabtme/rgbterm v0.0.0-20170906152045-cc83f3b3ce59/go.mod"
+#   "github.com/aybabtme/rgbterm v0.0.0-20170906152045-cc83f3b3ce59"
+# )
+#
+# go-mdoule_set_globals
 # SRC_URI="https://github.com/example/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-# Add this line if you have a dependency tarball.
-# SRC_URI+=" ${P}-deps.tar.xz"
+# SRC_URI+=" ${EGO_SUM_SRC_URI}"
 #
 # @CODE
 
@@ -105,11 +112,7 @@ QA_FLAGS_IGNORED='.*'
 RESTRICT+=" strip"
 
 # @ECLASS_VARIABLE: EGO_SUM
-# @DEPRECATED: none
 # @DESCRIPTION:
-# This is replaced by a dependency tarball, see above for how to create
-# one.
-#
 # This array is based on the contents of the go.sum file from the top
 # level directory of the software you are packaging. Each entry must be
 # quoted and contain the first two fields of a line from go.sum.
@@ -153,7 +156,6 @@ RESTRICT+=" strip"
 # go.sum copy of the Hash1 values during building of the package.
 
 # @ECLASS_VARIABLE: _GOMODULE_GOPROXY_BASEURI
-# @DEPRECATED: none
 # @DESCRIPTION:
 # Golang module proxy service to fetch module files from. Note that the module
 # proxy generally verifies modules via the Hash1 code.
@@ -176,7 +178,6 @@ RESTRICT+=" strip"
 : "${_GOMODULE_GOPROXY_BASEURI:=mirror://goproxy/}"
 
 # @ECLASS_VARIABLE: _GOMODULE_GOSUM_REVERSE_MAP
-# @DEPRECATED: none
 # @DESCRIPTION:
 # Mapping back from Gentoo distfile name to upstream distfile path.
 # Associative array to avoid O(N*M) performance when populating the GOPROXY
@@ -206,7 +207,6 @@ ego() {
 }
 
 # @FUNCTION: go-module_set_globals
-# @DEPRECATED: none
 # @DESCRIPTION:
 # Convert the information in EGO_SUM for other usage in the ebuild.
 # - Populates EGO_SUM_SRC_URI that can be added to SRC_URI
@@ -297,7 +297,6 @@ go-module_set_globals() {
 }
 
 # @FUNCTION: go-module_setup_proxy
-# @DEPRECATED: none
 # @DESCRIPTION:
 # If your ebuild redefines src_unpack and uses EGO_SUM you need to call
 # this function in src_unpack.
@@ -341,14 +340,11 @@ go-module_setup_proxy() {
 # @FUNCTION: go-module_src_unpack
 # @DESCRIPTION:
 # If EGO_SUM is set, unpack the base tarball(s) and set up the
-#   local go proxy. Also warn that this usage is deprecated.
+#   local go proxy.
 # - Otherwise, if EGO_VENDOR is set, bail out.
 # - Otherwise do a normal unpack.
 go-module_src_unpack() {
 	if [[ "${#EGO_SUM[@]}" -gt 0 ]]; then
-		eqawarn "This ebuild uses EGO_SUM which is deprecated"
-		eqawarn "Please migrate to a dependency tarball"
-		eqawarn "This will become a fatal error in the future"
 		_go-module_src_unpack_gosum
 	elif [[ "${#EGO_VENDOR[@]}" -gt 0 ]]; then
 		eerror "${EBUILD} is using EGO_VENDOR which is no longer supported"
@@ -359,7 +355,6 @@ go-module_src_unpack() {
 }
 
 # @FUNCTION: _go-module_src_unpack_gosum
-# @DEPRECATED: none
 # @DESCRIPTION:
 # Populate a GOPROXY directory hierarchy with distfiles from EGO_SUM and
 # unpack the base distfiles.
@@ -405,7 +400,6 @@ _go-module_src_unpack_gosum() {
 }
 
 # @FUNCTION: _go-module_gosum_synthesize_files
-# @DEPRECATED: none
 # @DESCRIPTION:
 # Given a path &  version, populate all Goproxy metadata files which aren't
 # needed to be downloaded directly.
@@ -433,7 +427,6 @@ _go-module_gosum_synthesize_files() {
 }
 
 # @FUNCTION: _go-module_src_unpack_verify_gosum
-# @DEPRECATED: none
 # @DESCRIPTION:
 # Validate the Go modules declared by EGO_SUM are sufficient to cover building
 # the package, without actually building it yet.
@@ -482,7 +475,6 @@ go-module_live_vendor() {
 }
 
 # @FUNCTION: _go-module_gomod_encode
-# @DEPRECATED: none
 # @DESCRIPTION:
 # Encode the name(path) of a Golang module in the format expected by Goproxy.
 #
-- 
2.35.1



  reply	other threads:[~2022-06-13  7:44 UTC|newest]

Thread overview: 58+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-13  7:44 [gentoo-dev] Proposal to undeprecate EGO_SUM Florian Schmaus
2022-06-13  7:44 ` Florian Schmaus [this message]
2022-06-13  9:49   ` [gentoo-dev] [PATCH] go-module.eclass: " Andrew Ammerlaan
2022-06-13 10:25     ` Florian Schmaus
2022-06-17 15:53   ` William Hubbs
2022-06-13  8:29 ` [gentoo-dev] Proposal to " Michał Górny
2022-06-13  8:49   ` Ulrich Mueller
2022-06-13  9:34     ` Florian Schmaus
2022-06-13 10:26       ` Ulrich Mueller
2022-06-17 16:27         ` William Hubbs
2022-10-12 13:01           ` Florian Schmaus
2022-06-13  9:30   ` Florian Schmaus
2022-06-13 11:03     ` Michał Górny
2022-06-14  9:37   ` Michał Górny
2022-06-14 10:29     ` Florian Schmaus
2022-06-14 16:33       ` [gentoo-dev] " Holger Hoffstätte
2022-06-14 17:03         ` Florian Schmaus
2022-06-15  5:53           ` Michał Górny
2022-06-17 19:04             ` Michał Górny
2022-06-14 17:34 ` [gentoo-dev] " Arsen Arsenović
2022-06-26 23:43 ` Zoltan Puskas
2022-06-27  6:09   ` Oskari Pirhonen
2022-06-27  7:14     ` Zoltan Puskas
2022-07-15 21:34   ` William Hubbs
2022-07-16 11:24     ` Florian Schmaus
2022-07-16 11:58       ` Joonas Niilola
2022-07-16 17:51         ` William Hubbs
2022-07-16 18:31           ` Arthur Zamarin
2022-07-16 18:46             ` Robin H. Johnson
2022-07-16 19:35               ` William Hubbs
2022-07-16 20:20                 ` Ulrich Mueller
2022-07-17  1:37                   ` William Hubbs
2022-09-28 15:28 ` Florian Schmaus
2022-09-28 16:31   ` Ulrich Mueller
2022-09-30  0:36     ` William Hubbs
2022-09-30 14:53       ` Florian Schmaus
2022-09-30 15:48         ` William Hubbs
2022-09-30 19:18         ` Sam James
2022-10-11 10:06           ` [gentoo-dev] RFC: check A's size in go-module.eclass Florian Schmaus
2022-10-11 10:06             ` [gentoo-dev] [PATCH] go-module.eclass: ensure that A is less than 112 KiB Florian Schmaus
2022-10-11 15:26               ` Mike Gilbert
2022-10-11 15:58                 ` Florian Schmaus
2022-10-11 15:33             ` [gentoo-dev] RFC: check A's size in go-module.eclass Mike Gilbert
2022-09-30 19:49         ` [gentoo-dev] Proposal to undeprecate EGO_SUM Alec Warner
2022-10-01  0:06           ` William Hubbs
2022-10-01 13:42           ` Florian Schmaus
2022-10-01 16:36             ` Ulrich Mueller
2022-10-01 17:21               ` Florian Schmaus
2022-10-01 20:59                 ` William Hubbs
2022-09-30 20:07       ` Arsen Arsenović
2022-09-30 23:49         ` William Hubbs
2022-09-28 21:23   ` John Helmert III
2022-09-30 13:57     ` Florian Schmaus
2022-09-30 14:36       ` Jaco Kroon
2022-09-30 14:53         ` Florian Schmaus
2022-09-30 15:10           ` Jaco Kroon
2022-09-30 15:32             ` Zoltan Puskas
2022-09-30 19:02   ` Georgy Yakovlev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220613074411.341909-2-flow@gentoo.org \
    --to=flow@gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    --cc=williamh@gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox