<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/poky.git/bitbake/lib/bb/fetch2/__init__.py, branch 5.2_M2</title>
<subtitle>Mirror of git.yoctoproject.org/poky</subtitle>
<id>https://git.enea.com/cgit/linux/poky.git/atom?h=5.2_M2</id>
<link rel='self' href='https://git.enea.com/cgit/linux/poky.git/atom?h=5.2_M2'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/'/>
<updated>2025-01-14T09:51:45+00:00</updated>
<entry>
<title>bitbake: bb/fetch2/__init__.py: remove a DeprecationWarning in uri_replace()</title>
<updated>2025-01-14T09:51:45+00:00</updated>
<author>
<name>Bin Lan</name>
<email>bin.lan.cn@windriver.com</email>
</author>
<published>2025-01-09T02:00:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=33271912bf25a51d86cf07f5d3e2042c04d17245'/>
<id>urn:sha1:33271912bf25a51d86cf07f5d3e2042c04d17245</id>
<content type='text'>
There is the following warning when executing to bitbake linux-yocto:
  bitbake/lib/bb/fetch2/__init__.py:464: DeprecationWarning: 'count' is passed as positional argument

This is because the 4th parameter of re.sub(pattern, repl, string, count=0, flags=0)
is a keyword parameter. We use keyword arguments for parameters that are not positional.

(Bitbake rev: 4bd62639f7023eec9f55ad7909fa9250538de936)

Signed-off-by: Bin Lan &lt;bin.lan.cn@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: utils: add Go mod h1 checksum support</title>
<updated>2025-01-11T18:35:01+00:00</updated>
<author>
<name>Stefan Herbrechtsmeier</name>
<email>stefan.herbrechtsmeier@weidmueller.com</email>
</author>
<published>2025-01-07T15:15:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=f00e8e1233e773d495413ea31000b88f67eb61ba'/>
<id>urn:sha1:f00e8e1233e773d495413ea31000b88f67eb61ba</id>
<content type='text'>
Add support for the Go mod h1 hash. The hash is based on the Go dirhash
package. The package defines hashes over directory trees and is uses for
Go mod files and zip archives.

(Bitbake rev: deefb01592f717efba68e3997fefd04dc7611d88)

Signed-off-by: Stefan Herbrechtsmeier &lt;stefan.herbrechtsmeier@weidmueller.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2: read checksum from SRC_URI flag for npm</title>
<updated>2025-01-08T11:34:04+00:00</updated>
<author>
<name>Stefan Herbrechtsmeier</name>
<email>stefan.herbrechtsmeier@weidmueller.com</email>
</author>
<published>2025-01-07T09:17:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=b242f0a0079bb1b9c19d663e144187af2fcc0605'/>
<id>urn:sha1:b242f0a0079bb1b9c19d663e144187af2fcc0605</id>
<content type='text'>
(Bitbake rev: 8d3232152e545be958f8f3b069e7477c6f310583)

Signed-off-by: Stefan Herbrechtsmeier &lt;stefan.herbrechtsmeier@weidmueller.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2: do not prefix embedded checksums</title>
<updated>2025-01-08T11:34:04+00:00</updated>
<author>
<name>Stefan Herbrechtsmeier</name>
<email>stefan.herbrechtsmeier@weidmueller.com</email>
</author>
<published>2025-01-07T09:17:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=d7c6afc9a97407238af814777f9148dedd507192'/>
<id>urn:sha1:d7c6afc9a97407238af814777f9148dedd507192</id>
<content type='text'>
The fetcher support entries with an embedded checksum like 'sha256sum'
in the SRC_URI. It adds the parameter 'name' as prefix to the checksums
if the parameter is set. This behavior is unexpected and leads to hacks
in fetchers. Fallback to the checksum without the useless prefix and
set the parameter 'name' in the gomod fetcher unconditional.

(Bitbake rev: 7a86c5a20ea2586f1ae240613644e065e7b21683)

Signed-off-by: Stefan Herbrechtsmeier &lt;stefan.herbrechtsmeier@weidmueller.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2: fix unpack of a single zstd file</title>
<updated>2024-11-29T18:26:14+00:00</updated>
<author>
<name>Pascal Eberhard</name>
<email>pascal.eberhard@se.com</email>
</author>
<published>2024-11-24T09:28:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=b35dc1a99d49710a981e024b0215d021afdb6c0f'/>
<id>urn:sha1:b35dc1a99d49710a981e024b0215d021afdb6c0f</id>
<content type='text'>
do_unpack generates a 'Bitbake Fetcher Error: UnpackError' when
uncompressing a single 'file.zst', zstd command line returns the error
'unexpected end of file', and the input file 'file.zst' becomes empty.

The command line is 'zstd --decompress --stdout file.zst &gt; file.zst'.
So the issue is that the input and output filenames are the same.

Fix the output filename when using zstd for a single file.

(Bitbake rev: 5881ca0e0d53937cd25a57ff682a3b7577b0b7f8)

Signed-off-by: Pascal Eberhard &lt;pascal.eberhard@se.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2: add GitHub Codespaces support</title>
<updated>2024-10-14T20:44:38+00:00</updated>
<author>
<name>Oliver Kästner</name>
<email>git@oliver-kaestner.de</email>
</author>
<published>2024-10-12T19:31:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=aa546ea0c316116d1f6f34f729a9e23f24322e0e'/>
<id>urn:sha1:aa546ea0c316116d1f6f34f729a9e23f24322e0e</id>
<content type='text'>
GitHub Codespaces allow users to use GitHub-hosted pre-configured Docker
containers to work on GitHub repositories in VS Code within the browser
or using a locally running instance of VS Code [1].

Users can define access permissions for Codespaces containers, allowing
them to clone or work with other private repositories [2].
To do this, a git credential helper is injected into the container at
/.codespaces/bin/gitcredential_github.sh, which contains the following
lines:

    #!/bin/sh
    echo protocol=https
    echo host=github.com
    echo path=
    echo username=PersonalAccessToken
    echo password=$GITHUB_TOKEN

The `GITHUB_TOKEN` environment variable is automatically set when the
Codespaces container is created. If authorized by the user, it has the
specified permissions. It is thus required to be able to fetch private
git repos from a Codespace container, so add it to `FETCH_EXPORT_VARS`
to make it available for invocations of git.

[1] https://docs.github.com/en/codespaces/overview
[2] https://docs.github.com/en/codespaces/managing-your-codespaces/managing-repository-access-for-your-codespaces

(Bitbake rev: 71ca83bdd541f70737a3a85f05e40c222611af2f)

Signed-off-by: Oliver Kästner &lt;git@oliver-kaestner.de&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: checksum/fetch2: Switch from persist_data to a standard cache file</title>
<updated>2024-10-09T12:04:30+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2024-10-08T12:36:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=76d24b00ff7db3f9b56bbca113e7fd1248c6a484'/>
<id>urn:sha1:76d24b00ff7db3f9b56bbca113e7fd1248c6a484</id>
<content type='text'>
The sqlite connection handling is causing problems with python 3.13. The
connection can be closed at gc time which causing warnings and those
can appear at 'random' points and break output, causing weird failures
in different tinfoil tools and other tests.

Using sqlite as an IPC was never a great idea so drop that usage entirely
and just use the standard cache mechanism we already have for other
situations.

(Bitbake rev: fdc55bb649cb77456d0ac48a9600ef289a52af18)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2: Avoid deprecation warning</title>
<updated>2024-10-09T12:04:30+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2024-10-08T12:36:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=8cd4ab4771c02c087655d06af90d060371318336'/>
<id>urn:sha1:8cd4ab4771c02c087655d06af90d060371318336</id>
<content type='text'>
&gt;From re on python 3.13 onwards: "Passing count and flags as positional arguments is deprecated.
In future Python versions they will be keyword-only parameters."

Avoid the warning.

(Bitbake rev: 016d872dc3c36792af5c84da1d35a5c86996d795)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2: don't try to preserve all attributes when unpacking files</title>
<updated>2024-09-30T16:01:25+00:00</updated>
<author>
<name>Ross Burton</name>
<email>ross.burton@arm.com</email>
</author>
<published>2024-09-25T11:10:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=d3a98ba77184a9863a037e5145772d51953ef796'/>
<id>urn:sha1:d3a98ba77184a9863a037e5145772d51953ef796</id>
<content type='text'>
When copying files as part of the unpack we currently use cp -p, which
is a shortcut for --preserve=mode,ownership,timestamps.

We do want to preserve timestamps, because some fetchers set these
explicitly.

We don't care about ownership. If the files are owned by us then they
ill remain owned by us, and if they're not then the attempt to change
ownership will be silently ignored.  In a shared DL_DIR where files have
group ownership this group access isn't relevant in the single-user build
tree.

We do want to preserve executable bits in the mode, but cp always does
this.  The difference between --preserve=mode and no --preserve is that
the mode isn't preserved exactly (no sticky bits, no suid, umask is
applied) but this also isn't a relevant difference in a build tree.

Also expand the arguments to be clearer about what options are being
passed.

The impetus for this is that coreutils 9.4 includes a change in gnulib[1]
and will now try to preserve permission-based xattrs if asked to preserve
the mode.  This can result in cp failing when copying a file from a
NFSv4 server with ACLs stored in xattrs to a non-NFS directory where
those xattrs cannot be written:

cp: preserving permissions for ‘./jquery-3.7.1.js’: Operation not supported

The error comes from the kernel refusing to write a system.nfs4_acl
xattr to a file on ext4.

This situation doesn't appear on all systems with coreutils 9.4, at the
time of writing it fails on Ubuntu 24.04 onwards but not Fedora 40. This
is because /etc/xattr.conf is used to determine which xattrs describe
permissions, and Fedora 40 has removed the NFSv4 attributes[2].

Also, use long-form options to make the cp command clearer.

[1] https://github.com/coreutils/gnulib/commit/eb6a8a4dfb
[2] https://src.fedoraproject.org/rpms/attr/blob/rawhide/f/0003-attr-2.4.48-xattr-conf-nfs4-acls.patch

[ YOCTO #15596 ]

(Bitbake rev: 2f35dac0c821ab231459922ed98e1b2cc599ca9a)

Signed-off-by: Ross Burton &lt;ross.burton@arm.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2: Add gomodgit fetcher</title>
<updated>2024-09-10T12:05:00+00:00</updated>
<author>
<name>Christian Lindeberg</name>
<email>christian.lindeberg@axis.com</email>
</author>
<published>2024-09-06T09:27:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=87c29b5a947956ab64c3fe881dfbc7eee5fef9e4'/>
<id>urn:sha1:87c29b5a947956ab64c3fe881dfbc7eee5fef9e4</id>
<content type='text'>
Add a go module fetcher for downloading module dependencies to the
module cache directly from a git repository. The fetcher can be used
with the go-mod class in OE-Core.

A module dependency can be specified with:

  SRC_URI += "gomodgit://golang.org/x/net;version=v0.9.0;srcrev=..."

(Bitbake rev: 29ff38ccf0d5389a5bee81e252a78548361a9d7c)

Signed-off-by: Christian Lindeberg &lt;christian.lindeberg@axis.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
</feed>
