public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: <Venkata.Pyla@toshiba-tsip.com>
To: <vijaikumar.kanagarajan@gmail.com>, <isar-users@googlegroups.com>
Subject: RE: [PATCH 1/2] rootfs.bbclass: clean blkid cache files from rootfs
Date: Wed, 9 Aug 2023 04:05:41 +0000	[thread overview]
Message-ID: <OSYPR01MB55424DA5116B5FA2FC7102BFA412A@OSYPR01MB5542.jpnprd01.prod.outlook.com> (raw)
In-Reply-To: <6340d949-acc1-4283-9713-01f584686929n@googlegroups.com>

[-- Attachment #1: Type: text/plain, Size: 2367 bytes --]



From: isar-users@googlegroups.com <isar-users@googlegroups.com> On Behalf Of vijai kumar
Sent: Monday, August 7, 2023 10:29 PM
To: isar-users <isar-users@googlegroups.com>
Subject: Re: [PATCH 1/2] rootfs.bbclass: clean blkid cache files from rootfs


On Monday, August 7, 2023 at 10:05:21 PM UTC+5:30 venkat...@toshiba-tsip.com<mailto:venkat...@toshiba-tsip.com> wrote:
From: venkata pyla <venkat...@toshiba-tsip.com>

Sometimes `blkid` generates cached files `/run/blkid/blkdid.tab*`, these
cache files are not reproducible and not necessary in the final image,
so remove them to achieve reproducible builds.

Signed-off-by: venkata pyla <venkat...@toshiba-tsip.com>
---
meta/classes/rootfs.bbclass | 6 ++++++
1 file changed, 6 insertions(+)

diff --git a/meta/classes/rootfs.bbclass b/meta/classes/rootfs.bbclass
index 22449d71..5d493ea2 100644
--- a/meta/classes/rootfs.bbclass
+++ b/meta/classes/rootfs.bbclass
@@ -293,6 +293,12 @@ rootfs_export_dpkg_status() {
'${ROOTFS_DPKGSTATUS_DEPLOY_DIR}'/'${ROOTFS_PACKAGE_SUFFIX}'.dpkg_status
}

+ROOTFS_POSTPROCESS_COMMAND += "rootfs_postprocess_clean_blkid_cache"
+rootfs_postprocess_clean_blkid_cache() {
+ # blkid generates cache file which are not reproducible
+ sudo rm -rf "${ROOTFSDIR}/run/blkid/blkid.tab"*
+}

If this is a necessary clean up function, can we not move to rootfs_finalize? Or maybe adding it to ROOTFS_CLEAN_FILES?

There is no issue to keep this cleaning in `rootfs_finalize`, in fact it is more meaning full to keep all cleanup in finalize methods.

Thanks for the suggestion, I will change in v2.

Thanks,
Vijai Kumar K

+
do_rootfs_postprocess[vardeps] = "${ROOTFS_POSTPROCESS_COMMAND}"
do_rootfs_postprocess[network] = "${TASK_USE_SUDO}"
python do_rootfs_postprocess() {
--
2.20.1

--
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com<mailto:isar-users+unsubscribe@googlegroups.com>.
To view this discussion on the web visit https://groups.google.com/d/msgid/isar-users/6340d949-acc1-4283-9713-01f584686929n%40googlegroups.com<https://groups.google.com/d/msgid/isar-users/6340d949-acc1-4283-9713-01f584686929n%40googlegroups.com?utm_medium=email&utm_source=footer>.

[-- Attachment #2: Type: text/html, Size: 6243 bytes --]

  reply	other threads:[~2023-08-09  4:05 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-07 16:35 [PATCH 0/2] Fix reproducible issues in armhf venkata.pyla
2023-08-07 16:35 ` [PATCH 1/2] rootfs.bbclass: clean blkid cache files from rootfs venkata.pyla
2023-08-07 16:58   ` vijai kumar
2023-08-09  4:05     ` Venkata.Pyla [this message]
2023-08-09 13:47       ` [PATCH v2 0/2] Fix reproducible issues in armhf venkata.pyla
2023-08-14 11:57         ` vijai kumar
2023-08-15 14:59         ` Uladzimir Bely
2023-08-09 13:47       ` [PATCH v2 1/2] image.bbclass: remove core files generated in rootfs venkata.pyla
2023-08-09 13:47       ` [PATCH v2 2/2] image.bbclass: clean blkid cache files from rootfs venkata.pyla
2023-08-31  6:16     ` [PATCH 1/2] rootfs.bbclass: " MOESSBAUER, Felix
2023-08-07 16:35 ` [PATCH 2/2] image.bbclass: remove core files generated in rootfs venkata.pyla
2023-08-31  6:21   ` MOESSBAUER, Felix

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=OSYPR01MB55424DA5116B5FA2FC7102BFA412A@OSYPR01MB5542.jpnprd01.prod.outlook.com \
    --to=venkata.pyla@toshiba-tsip.com \
    --cc=isar-users@googlegroups.com \
    --cc=vijaikumar.kanagarajan@gmail.com \
    /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