From: ecordonnier@snap.com
To: openembedded-core@lists.openembedded.org
Cc: Etienne Cordonnier <ecordonnier@snap.com>
Subject: [PATCH v4 0/2] archiver.bbclass: archive shallow git sources without a clone, drop .git
Date: Wed, 2 Dec 2026 21:54:44 +0100 [thread overview]
Message-ID: <20261202205446.2442999-1-ecordonnier@snap.com> (raw)
From: Etienne Cordonnier <ecordonnier@snap.com>
In "original" mode, a git source fetched through a shallow tarball (fast
initial shallow fetch, or a tarball from a mirror) has no clone in DL_DIR, so
do_ar_original silently skipped it. This series archives it, and removes the
useless .git from the archives of git sources.
Etienne Cordonnier (2):
archiver.bbclass: unpack original sources without a localpath
archiver.bbclass: remove .git from original git source archives
v4:
- Follow Paul's review of v3: no fetcher-specific code in do_ar_original.
A source is copied if localpath() is a file, otherwise it is unpacked
with fetch.unpack() and it is an error if nothing was unpacked.
- Drop the bitbake patch from v3 (return the shallow tarball as
localpath): with the above, the archiver no longer depends on
localpath() existing for git.
- Fold the "fail on sources which cannot be archived" patch into 1/2.
- Add selftests for plain git, gitsm and nocheckout.
v3:
- Add a bitbake patch so localpath() exists after do_fetch when the shallow
tarball is used without a clone, as suggested in the v2 review, and drop
the shallow special case from the archiver.
v2:
- Combined the two v1 patches into one series, as requested.
- Split "archive shallow git sources which have no clone" into 1/3 (archive
the shallow source) and 2/3 (remove .git), and 2/3 now removes .git for
all git sources, including the .git files of submodules (kept for
nocheckout/bareclone).
- 3/3 ("warn about sources which are not archived" in v1) now raises a
fatal error.
meta/classes/archiver.bbclass | 23 ++++-
meta/lib/oeqa/selftest/cases/archiver.py | 111 +++++++++++++++++++++++
2 files changed, 131 insertions(+), 3 deletions(-)
base-commit: 4b4fc6d149e030f8d2d60f6a4e44a44d56cb8082
--
2.43.0
next reply other threads:[~2026-12-02 20:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-02 20:54 ecordonnier [this message]
2026-12-02 20:54 ` [PATCH v4 1/2] archiver.bbclass: unpack original sources without a localpath ecordonnier
2026-12-02 20:54 ` [PATCH v4 2/2] archiver.bbclass: remove .git from original git source archives ecordonnier
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=20261202205446.2442999-1-ecordonnier@snap.com \
--to=ecordonnier@snap.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