Skip to contentSkip to conversation

Growing rootfs.cpio after each make

Buildroot Andreas Ziegler 1 participant 1 message Apr 26, 2024 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

Hi Andrey,

Quoted 2 lines · Andrey Nechypurenko

Hi Folks,
Am I the only one with the problem mentioned below? :-)

Probably you are unique in that respect. The rootfs.cpio is deleted before re-creating it. Things that change with each call to make are:

Target directory finalization
The rootfs overlay files are rsynced into the target directory Post-build scripts are executed
User and device tables are generated
The cpio is created by cloning the target directory

Quoted 8 lines · Andrey Nechypurenko
Quoted 7 lines

Hi Buildrooters,

I have BR2_TARGET_ROOTFS_CPIO enabled and just realized that every time I run make in the build directory, the images/rootfs.cpio file is growing. Even deleting the file before make still results in an ever growing file.

You will have a size increase whenever you change package software versions and the resulting binary uses the full version string in its name. E.g. changing the kernel version will result in an additional directory in target/lib/modules.

If your image changes size by itself, maybe there is some process which leaves files behind in the target directory, for example a post-build script? In that case, check if file permissions allow unrestricted creation /deletion of files for your user id.

Quoted 6 lines
Quoted 6 lines

So I am wondering why it is happening and if there is any way to prevent this without running make clean all or similar? Maybe some kind of pre- or post-build scripts?

Thank you,
Andrey.

Kind regards,
Andreas
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot