All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] Growing rootfs.cpio after each make
@ 2024-04-19 11:34 Andrey Nechypurenko
  2024-04-24 13:28 ` Andrey Nechypurenko
  2024-04-28 17:45 ` Arnout Vandecappelle via buildroot
  0 siblings, 2 replies; 4+ messages in thread
From: Andrey Nechypurenko @ 2024-04-19 11:34 UTC (permalink / raw)
  To: buildroot

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.

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.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Buildroot] Growing rootfs.cpio after each make
  2024-04-19 11:34 [Buildroot] Growing rootfs.cpio after each make Andrey Nechypurenko
@ 2024-04-24 13:28 ` Andrey Nechypurenko
  2024-04-28 17:45 ` Arnout Vandecappelle via buildroot
  1 sibling, 0 replies; 4+ messages in thread
From: Andrey Nechypurenko @ 2024-04-24 13:28 UTC (permalink / raw)
  To: buildroot

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

On Fri, 19 Apr 2024 at 13:34, Andrey Nechypurenko <andreynech@gmail.com> wrote:
>
> 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.
>
> 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.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Buildroot] Growing rootfs.cpio after each make
  2024-04-19 11:34 [Buildroot] Growing rootfs.cpio after each make Andrey Nechypurenko
  2024-04-24 13:28 ` Andrey Nechypurenko
@ 2024-04-28 17:45 ` Arnout Vandecappelle via buildroot
  1 sibling, 0 replies; 4+ messages in thread
From: Arnout Vandecappelle via buildroot @ 2024-04-28 17:45 UTC (permalink / raw)
  To: Andrey Nechypurenko, buildroot



On 19/04/2024 13:34, Andrey Nechypurenko wrote:
> 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.
> 
> So I am wondering why it is happening and if there is any way to

  It's not the cpio by itself that is growing, it's the contents (i.e. 
output/target) that is growing. The cpio is simply a packing up output/target 
with a bit of additional processing (e.g. setting permissions).

  Now, why your output/target is growing, I can't really give you an answer. If 
you really want to know, you could make a copy of it, then rebuild, then take 
the difference between the copy and the rebuilt output/target. You can also take 
a look at output/build/packages-file-list.txt to see which package created the 
files that are growing.

  I suspect a post-build script, but that's just because I can then put the 
blame on you :-)

  Regards,
  Arnout


> prevent this without running make clean all or similar? Maybe some
> kind of pre- or post-build scripts?
> 
> Thank you,
> Andrey.
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Buildroot] Growing rootfs.cpio after each make
       [not found] <mailman.16000.1714065752.13795.buildroot@buildroot.org>
@ 2024-04-26  6:27 ` Andreas Ziegler
  0 siblings, 0 replies; 4+ messages in thread
From: Andreas Ziegler @ 2024-04-26  6:27 UTC (permalink / raw)
  To: Andrey Nechypurenko; +Cc: buildroot

Hi Andrey,

On 2024-04-25 17:22, Andrey Nechypurenko wrote:
> 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

> On Fri, 19 Apr 2024 at 13:34, Andrey Nechypurenko 
> <andreynech@gmail.com> wrote:
>> 
>> 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.

>> 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
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-04-28 17:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-19 11:34 [Buildroot] Growing rootfs.cpio after each make Andrey Nechypurenko
2024-04-24 13:28 ` Andrey Nechypurenko
2024-04-28 17:45 ` Arnout Vandecappelle via buildroot
     [not found] <mailman.16000.1714065752.13795.buildroot@buildroot.org>
2024-04-26  6:27 ` Andreas Ziegler

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.