From: Ryan Eatmon <reatmon@ti.com>
To: Christian Lindeberg <christian.lindeberg@axis.com>,
<openembedded-core@lists.openembedded.org>
Subject: Re: [OE-core] [PATCH] go-mod.bbclass: Set GO_MOD_CACHE_DIR
Date: Thu, 12 Sep 2024 15:13:58 -0500 [thread overview]
Message-ID: <dbf01538-aab4-47a7-b167-3cf3c4eea94f@ti.com> (raw)
In-Reply-To: <20240912142953.1580877-1-christli@axis.com>
On 9/12/2024 9:29 AM, Christian Lindeberg wrote:
> From: Christian Lindeberg <christian.lindeberg@axis.com>
>
> Set the GO_MOD_CACHE_DIR variable and move the location of the module
> cache to enable the use of the go module fetchers for module
> dependencies.
> Also, clean out the module cache before unpacking.
>
> Signed-off-by: Christian Lindeberg <christian.lindeberg@axis.com>
> ---
> meta/classes-recipe/go-mod.bbclass | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/meta/classes-recipe/go-mod.bbclass b/meta/classes-recipe/go-mod.bbclass
> index ca3a690d05..71a6712c47 100644
> --- a/meta/classes-recipe/go-mod.bbclass
> +++ b/meta/classes-recipe/go-mod.bbclass
> @@ -22,9 +22,9 @@ GOBUILDFLAGS:append = " -modcacherw"
>
> inherit go
>
> +GO_MOD_CACHE_DIR ?= "${@os.path.join(os.path.basename(d.getVar('S')), 'pkg/mod')}"
> +export GOMODCACHE = "${@os.path.join(os.path.dirname(d.getVar('S')), d.getVar('GO_MOD_CACHE_DIR'))}"
> +do_unpack[cleandirs] += "${GOMODCACHE}"
> +
> GO_WORKDIR ?= "${GO_IMPORT}"
> do_compile[dirs] += "${B}/src/${GO_WORKDIR}"
> -
> -export GOMODCACHE = "${B}/.mod"
> -
> -do_compile[cleandirs] += "${B}/.mod"
>
What is the reasoning behind moving the cache dir out of the build dir
${B} and into the bitbake managed sources dir ${S} ? There might be a
good reason for doing it, but it was not explained in the commit message.
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#204444): https://lists.openembedded.org/g/openembedded-core/message/204444
> Mute This Topic: https://lists.openembedded.org/mt/108413937/6551054
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [reatmon@ti.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
--
Ryan Eatmon reatmon@ti.com
-----------------------------------------
Texas Instruments, Inc. - LCPD - MGTS
next prev parent reply other threads:[~2024-09-12 20:14 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-12 14:29 [PATCH] go-mod.bbclass: Set GO_MOD_CACHE_DIR Christian Lindeberg
2024-09-12 17:00 ` [OE-core] " Jose Quaresma
2024-09-12 21:49 ` Peter Kjellerstedt
2024-09-13 7:52 ` Christian Lindeberg
2024-09-12 20:13 ` Ryan Eatmon [this message]
2024-09-13 8:16 ` Christian Lindeberg
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=dbf01538-aab4-47a7-b167-3cf3c4eea94f@ti.com \
--to=reatmon@ti.com \
--cc=christian.lindeberg@axis.com \
--cc=openembedded-core@lists.openembedded.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