From: Alexander Kanavin <alex.kanavin@gmail.com>
To: openembedded-core@lists.openembedded.org
Cc: Alexander Kanavin <alex@linutronix.de>
Subject: [PATCH 2/2] scripts/install-buildtools: write download URLs to files for traceability
Date: Tue, 11 Mar 2025 11:41:52 +0100 [thread overview]
Message-ID: <20250311104152.393470-2-alex.kanavin@gmail.com> (raw)
In-Reply-To: <20250311104152.393470-1-alex.kanavin@gmail.com>
From: Alexander Kanavin <alex@linutronix.de>
This extends the previous commit, so that download URLs are preserved
in addition to actual artefacts. By default it's all written to a temporary
directory and erased together with artefacts, but users can choose
to preserve both:
$ install-buildtools -D --keep-downloads-directory=.
...
$ ls -1
buildtools_url
check_url
x86_64-buildtools-extended-nativesdk-standalone-5.1.2.sh
x86_64-buildtools-extended-nativesdk-standalone-5.1.2.sh.sha256sum
Signed-off-by: Alexander Kanavin <alex@linutronix.de>
---
scripts/install-buildtools | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/scripts/install-buildtools b/scripts/install-buildtools
index 1a68aad53e7..7bd6556edf6 100755
--- a/scripts/install-buildtools
+++ b/scripts/install-buildtools
@@ -243,6 +243,8 @@ def main():
# Fetch installer
logger.info("Fetching buildtools installer")
tmpbuildtools = os.path.join(sdk_dir, filename)
+ with open(os.path.join(sdk_dir, 'buildtools_url'), 'w') as f:
+ f.write(buildtools_url)
ret = subprocess.call("wget -q -O %s %s" %
(tmpbuildtools, buildtools_url), shell=True)
if ret != 0:
@@ -256,6 +258,8 @@ def main():
check_url = "{}.{}".format(buildtools_url, checksum_type)
checksum_filename = "{}.{}".format(filename, checksum_type)
tmpbuildtools_checksum = os.path.join(sdk_dir, checksum_filename)
+ with open(os.path.join(sdk_dir, 'check_url'), 'w') as f:
+ f.write(check_url)
ret = subprocess.call("wget -q -O %s %s" %
(tmpbuildtools_checksum, check_url), shell=True)
if ret != 0:
--
2.39.5
next prev parent reply other threads:[~2025-03-11 10:42 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-11 10:41 [PATCH 1/2] scripts/install-buildtools: add an option to preserve downloads Alexander Kanavin
2025-03-11 10:41 ` Alexander Kanavin [this message]
2025-03-13 11:17 ` [OE-core] [PATCH 2/2] scripts/install-buildtools: write download URLs to files for traceability Richard Purdie
2025-03-11 10:46 ` Patchtest results for [PATCH 1/2] scripts/install-buildtools: add an option to preserve downloads patchtest
2025-03-13 11:03 ` [OE-core] " Antonin Godard
2025-03-13 11:15 ` Richard Purdie
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=20250311104152.393470-2-alex.kanavin@gmail.com \
--to=alex.kanavin@gmail.com \
--cc=alex@linutronix.de \
--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