cleanup-workdir
Hello Kai,
because I was low on disk space, I just tried scripts/cleanup-workdir for the first time. My observations:
1.) It deletes work directories that were built for other machines (archs) than the current one. I guess the list of architectures to handle should be queried from bitbake to avoid this.
2.) It doesn't delete work directories of previously deleted recipes.
Regards,
Andreas
Quoted 4 lines · Andreas Oberritter
Hello Kai,
because I was low on disk space, I just tried
scripts/cleanup-workdirfor the first time. My observations:
Hi Andreas,
Quoted 3 lines
1.) It deletes work directories that were built for other machines (archs) than the current one. I guess the list of architectures to handle should be queried from bitbake to avoid this.
Do you mean that you build for 2 archs under the same "build" directory? Even in this way the script only delete the packages' build dir for old versions. Your requirement is that cleanup-workdir just clean the build dirs for current arch, right?
Quoted 1 line
2.) It doesn't delete work directories of previously deleted recipes.
Because when the recipe gone, I can NOT tell whether the directory is left by bitbake or created by user. I will list them and let user to choose delete them or not.
Regards,
Kai
Quoted 3 lines
Regards,
Andreas
Quoted 6 lines · Kang Kai
Quoted 4 lines · Andreas Oberritter
Hello Kai,
because I was low on disk space, I just tried
scripts/cleanup-workdirfor the first time. My observations:
Quoted 7 lines
Hi Andreas,
Quoted 3 lines
1.) It deletes work directories that were built for other machines (archs) than the current one. I guess the list of architectures to handle should be queried from bitbake to avoid this.
Do you mean that you build for 2 archs under the same "build" directory?
I have two build directories, one for each machine, sharing a single tmp directory.
The basic layout looks roughly like this:
$OE/build/machineA/conf/local.conf$OE/build/machineB/conf/local.conf
$OE/tmp/work/
Quoted 2 lines
Even in this way the script only delete the packages' build dir for old versions.
That's right, but different machines may have different versions due to COMPATIBLE_MACHINE settings. In my setup, there's also a layer for each machine, which contains hardware drivers etc. Although every machine provides the same set of drivers (same ${PN}), the versions differ slightly.
Quoted 2 lines
Your requirement is that cleanup-workdir just clean the build dirs for current arch, right?
Yes. For each arch listed in PACKAGE_ARCHS (or ALL_MULTILIB_PACKAGE_ARCHS?) for the current machine.
Quoted 4 lines
Quoted 1 line
2.) It doesn't delete work directories of previously deleted recipes.
Because when the recipe gone, I can NOT tell whether the directory is left by bitbake or created by user.
I will list them and let user to choose delete them or not.
It should be safe to assume that there are no directories created by the user, as tmp/work is known to be managed by OE. However, recipes don't disappear very often, so asking the user seems to be fine.
Regards,
Andreas
Quoted 38 lines · Andreas Oberritter
Quoted 6 lines · Kang Kai
Quoted 4 lines · Andreas Oberritter
Hello Kai,
because I was low on disk space, I just tried
scripts/cleanup-workdirfor the first time. My observations:Quoted 7 lines
Hi Andreas,
Quoted 3 lines
1.) It deletes work directories that were built for other machines (archs) than the current one. I guess the list of architectures to handle should be queried from bitbake to avoid this.
Do you mean that you build for 2 archs under the same "build" directory?
I have two build directories, one for each machine, sharing a single tmp directory.
The basic layout looks roughly like this:
$OE/build/machineA/conf/local.conf$OE/build/machineB/conf/local.conf
$OE/tmp/work/Quoted 2 lines
Even in this way the script only delete the packages' build dir for old versions.
That's right, but different machines may have different versions due to
COMPATIBLE_MACHINEsettings. In my setup, there's also a layer for each machine, which contains hardware drivers etc. Although every machine provides the same set of drivers (same ${PN}), the versions differ slightly.Quoted 2 lines
Your requirement is that cleanup-workdir just clean the build dirs for current arch, right?
Yes. For each arch listed in
PACKAGE_ARCHS(orALL_MULTILIB_PACKAGE_ARCHS?) for the current machine.
Quoted 8 lines
Quoted 4 lines
Quoted 1 line
2.) It doesn't delete work directories of previously deleted recipes.
Because when the recipe gone, I can NOT tell whether the directory is left by bitbake or created by user.
I will list them and let user to choose delete them or not.It should be safe to assume that there are no directories created by the user, as tmp/work is known to be managed by OE. However, recipes don't disappear very often, so asking the user seems to be fine.
Yes, it ignored the following package directories from removed recipes: module-init-tools-3.16-r0 & module-init-tools-cross-3.16-r0. My preference would be to have the tool delete them.
I also noticed that the regex filters missed "iputils-s20101006-r3", so a tweak to pick this up is probably warranted (or at least flag it at the bottom of the regex loop as not being matched by any of the filters).
Related question: why not add an option to the tool to have it go ahead and also delete the artifacts from the obsolete packages left in stamps and buildstats?
Quoted 8 lines
Regards,
Andreas_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core