summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* go-module.eclass: fix eclassdoc @DEPRECATION tagsSam James2022-04-151-9/+9
| | | | | Thanks-to: Ionen Wolkens <ionen@gentoo.org> Signed-off-by: Sam James <sam@gentoo.org>
* *.eclass: @ECLASS-VARIABLE renamed to @ECLASS_VARIABLEUlrich Müller2022-03-241-4/+4
| | | | | Bug: https://bugs.gentoo.org/835396 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* go-module.eclass: fix EclassDocError for @DEPRECATEDSam James2022-03-181-9/+9
| | | | | | No trailing colon (:). Signed-off-by: Sam James <sam@gentoo.org>
* go-module.eclass: invoke "ego mod tidy" with nonfatalFlorian Schmaus2022-03-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We previously invoked "mod tidy" without the ego helper function in a non-fatal way. This was switched to using the ego helper in f9ee55e698f8 ("go-module.eclass: use ego helper function") but without prefixing the call with nonfatal. Hence the semantic of the eclass changes: a previously non-fatal invocation became fatal, causing e.g., bug #834695. [sam: fixes semantic change which wasn't advertised/seemingly intentional, so let's get this in now to avoid a significant number of ebuilds being broken. We can introduce this change if desired at a later point. Fixes: f9ee55e698f8 ("go-module.eclass: use ego helper function") Closes: https://bugs.gentoo.org/834758 Closes: https://bugs.gentoo.org/834762 Closes: https://bugs.gentoo.org/834607 Closes: https://bugs.gentoo.org/834608 Closes: https://bugs.gentoo.org/834625 Closes: https://bugs.gentoo.org/834626 Closes: https://bugs.gentoo.org/834630 Closes: https://bugs.gentoo.org/834669 Closes: https://bugs.gentoo.org/834603 Closes: https://bugs.gentoo.org/834610 Closes: https://bugs.gentoo.org/834711 Closes: https://bugs.gentoo.org/834763 Signed-off-by: Florian Schmaus <flow@gentoo.org> Closes: https://github.com/gentoo/gentoo/pull/24437 Signed-off-by: Sam James <sam@gentoo.org>
* go-module.eclass: deprecate EGO_SUMWilliam Hubbs2022-03-061-12/+33
| | | | | | | | | EGO_SUM can be thousands of lines long in ebuilds, and it leads to creating Manifest files that are thousands of lines long. It has been determined that dependency tarballs are a better solution if upstream doesn't vendor their dependencies. Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: clarify the instructions around GO_OPTIONALWilliam Hubbs2022-03-041-5/+3
| | | | | | | remove the version of dev-lang/go since we do not know which version the ebuild author will need to depend on. Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: put the go module cache under the work directoryWilliam Hubbs2022-03-041-3/+1
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: use ego helper functionWilliam Hubbs2022-03-041-2/+2
| | | | | | | All direct calls to go in eclasses or ebuilds should be done via the ego helper function. Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: add helper function to call goWilliam Hubbs2022-02-251-0/+13
| | | | | | | | This function will cause the ebuild to die if Go fails. Also, it outputs the go command that is being run. Closes: https://bugs.gentoo.org/833497 Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: set a default for GOMODCACHEWilliam Hubbs2022-02-181-0/+6
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: add a manual example of how to extract the content of EGO_SUMWilliam Hubbs2022-02-171-0/+8
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: update documentationWilliam Hubbs2022-02-161-6/+14
| | | | | | - document the minimum version of go that should be listed in go.mod. - show how to generate the contents of EGO_SUM Signed-off-by: William Hubbs <williamh@gentoo.org>
* eclass/go-module.eclass: documentation and bdepend adjustmentWilliam Hubbs2022-02-131-6/+8
| | | | | | | | Update the documentation to not refer to golang* eclasses. Bump the go dependency to 1.16 so the behavior for modules is consistent. Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass fixed referenced packageDennis Lamm2022-01-211-1/+1
| | | | | | | | | dev-util/golicense -> dev-go/golicense Signed-off-by: Dennis Lamm <expeditioneer@gentoo.org> Package-Manager: Portage-3.0.28, Repoman-3.0.3 Closes: https://github.com/gentoo/gentoo/pull/23890 Signed-off-by: Sam James <sam@gentoo.org>
* go-module.eclass: Add GO_OPTIONAL flagFlorian Schmaus2021-12-111-9/+22
| | | | | | | | | | Following the pattern found in other eclasses, add GO_OPTIONAL to the go-module eclass. This allows inheriting the eclass without pulling its dependencies or exporting the unpack function. See, e.g., bug #775779 for the motivation. Signed-off-by: Florian Schmaus <flow@gentoo.org> Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-modules.eclass: allow the module cache to be read/writeWilliam Hubbs2021-09-231-1/+1
| | | | | | | | | | | | | | | This allows the modules to be cleaned up on prefix systems. More information is available here: https://github.com/golang/go/issues/27161 I would like to thank Raffaele Spinelli <rafspiny@gmail.com> for the original patch this was based on. Closes: https://bugs.gentoo.org/812977 Closes: https://github.com/gentoo/gentoo/pull/22365 Signed-off-by: William Hubbs <williamh@gentoo.org>
* Revert "go-module.eclass: Set @PROVIDES"Sam James2021-09-111-2/+1
| | | | | | | | This reverts commit 9f41c938a745479414544fa9c03aaa1b6d9b989b. Doesn't inherit it! Signed-off-by: Sam James <sam@gentoo.org>
* go-module.eclass: Set @PROVIDESMichał Górny2021-09-111-1/+2
| | | | | Signed-off-by: Michał Górny <mgorny@gentoo.org> Signed-off-by: Sam James <sam@gentoo.org>
* go-module.eclass: drop the go-module_pkg_postinst functionWilliam Hubbs2021-09-011-16/+1
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: drop --mod=readonly from GOFLAGSWilliam Hubbs2021-09-011-3/+1
| | | | | | | | | As of go 1.16, --mod=readonly is the default, so we don't need to specify it. https://golang.org/ref/mod#build-commands https://golang.org/doc/go1.16 Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: add eapi 8 supportWilliam Hubbs2021-07-061-4/+4
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: add go-module_setup_proxy functionWilliam Hubbs2021-05-251-0/+41
| | | | | | | This function is to be used in an ebuild that uses EGO_SUM and defines src_unpack. Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: fix GOPROXY exportWilliam Hubbs2021-05-251-2/+4
| | | | | | | This variable should be exported in the go-module_set_globals function since it is not needed unless EGO_SUM is used. Signed-off-by: William Hubbs <williamh@gentoo.org>
* eclass/go-module.eclass: add a missing die callWilliam Hubbs2020-09-141-1/+1
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* eclass/go-module.eclass: remove EGO_VENDOR supportWilliam Hubbs2020-06-121-75/+6
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* eclass/go-module: remove go-get for corner case of unneeded deep build ↵Robin H. Johnson2020-03-101-11/+6
| | | | | | | | | | | | | | dependencies The helper function used to call 'go get' to verify by fake-fetching everything from the main go.mod. However 'go get' also turns out to recursively try to fetch everything in dependencies, even materials that are used only for tests of the dependencies, or code generation. If EGO_SUM is missing an entry now, it will fail during the build process rather than the helper function. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
* go-module.eclass: replace GOFLAGS if EGO_VENDOR is being usedWilliam Hubbs2020-03-101-1/+3
| | | | | | | | | We can't repeat the -mod flag, so we need to replace the GOFLAGS if EGO_VENDOR is being used. Closes: https://bugs.gentoo.org/7111640 Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: fix regression with -mod=vendor settingWilliam Hubbs2020-03-101-1/+1
| | | | | | | | If EGO_VENDOR is tested in global scope, it needs to be set before the eclass is inherited. Several ebuilds do not do this, so we need to perform this test and set -mod=vendor in the appropriate phase function. Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: fix strip restrictionWilliam Hubbs2020-03-081-1/+1
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* eclass/go-module: clarify that h1: should be omitted from EGO_SUMRobin H. Johnson2020-03-071-4/+22
| | | | Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
* go-module: workaround MissingUnpackerDep QA false positiveRobin H. Johnson2020-03-071-0/+6
| | | | | | | | | | | | | | | | | The go.sum behavior in this eclass triggers a false positive from pkgcheck, specifically: MissingUnpackerDep: version ...: missing BDEPEND="app-arch/unzip" The eclass & package do NOT invoke any direct unpacking of the zipfiles, and leave that entirely to Go's builtin code, making app-arch/unzip completely unneeded. Adding packages using the new eclass functionality will spam the above MissingUnpackerDep warning, so workaround it for now, until pkgcheck/QA can not give the false positive. Reference: https://github.com/pkgcore/pkgcheck/issues/214 Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
* go-module.eclass: remove the -mod readonly switch from go getWilliam Hubbs2020-03-061-2/+0
| | | | | | | This is not valid in go 1.14, and according to their release notes was ignored or caused the build to fail. Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: add support for EGO_SUMWilliam Hubbs2020-03-041-40/+326
| | | | | | The EGO_SUM variable replaces EGO_VENDOR for go modules. Signed-off-by: William Hubbs <williamh@gentoo.org>
* */*: Bump copyright on files touched this yearMichał Górny2020-02-111-1/+1
| | | | | | | Update the copyright notice on all files that were touched since January 1st but did not have the notice updated. Signed-off-by: Michał Górny <mgorny@gentoo.org>
* go-module.eclass: Fix case in copyrightMichał Górny2020-01-261-1/+1
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* go-module.eclass: set a reasonable default for the go build cacheWilliam Hubbs2020-01-061-0/+4
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: only show warning for new packagesWilliam Hubbs2019-10-021-0/+1
| | | | Signed-off-by: William Hubbs <williamh@gentoo.org>
* go-module.eclass: new eclass for go modulesWilliam Hubbs2019-09-301-0/+177
This eclass includes the basic settings and src_unpack/pkg_postinst functions for software written in the Go programming language that uses Go modules. Signed-off-by: William Hubbs <williamh@gentoo.org>