* [PATCH 0/3]sstate-cache-management.sh: fix remove duplicate failed when multiple archs
@ 2013-02-26 7:57 Hongxu Jia
2013-02-26 7:57 ` [PATCH 1/3] sstate-cache-management.sh: " Hongxu Jia
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Hongxu Jia @ 2013-02-26 7:57 UTC (permalink / raw)
To: openembedded-core
The following changes since commit 7d22ef28e64de06b6238d0ef9b664c0bee6efa46:
bitbake: Revert "fetch2: Adapt encode/decode url to use URI class" (2013-02-19 23:07:23 -0800)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib hongxu/fix-sstate-mngt-sh
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-sstate-mngt-sh
Hongxu Jia (3):
sstate-cache-management.sh: fix remove duplicate failed when multiple
archs
sstate-cache-management.sh: don't hardcode available sstate_suffixes
sstate-cache-management.sh:fix the incorrect usage of option `-d'
scripts/sstate-cache-management.sh | 17 ++++++++++++-----
1 file changed, 12 insertions(+), 5 deletions(-)
--
1.7.10.4
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH 1/3] sstate-cache-management.sh: fix remove duplicate failed when multiple archs
2013-02-26 7:57 [PATCH 0/3]sstate-cache-management.sh: fix remove duplicate failed when multiple archs Hongxu Jia
@ 2013-02-26 7:57 ` Hongxu Jia
2013-02-26 7:57 ` [PATCH 2/3] sstate-cache-management.sh: don't hardcode available sstate_suffixes Hongxu Jia
2013-02-26 7:57 ` [PATCH 3/3] sstate-cache-management.sh:fix the incorrect usage of option `-d' Hongxu Jia
2 siblings, 0 replies; 4+ messages in thread
From: Hongxu Jia @ 2013-02-26 7:57 UTC (permalink / raw)
To: openembedded-core
The implementation of `--remove-duplicated' has been modified by the commit:
http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=0740f82aea92da0195524e37c372f9981e7f5e6d
In above commit, sstate cache files with multiple archs are not considered
duplicate and don't need to be removed as duplicated any more.
Update the description of `--remove-duplicated' in usage to keep consistent
with implementation.
[YOCTO #3635]
Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
---
scripts/sstate-cache-management.sh | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/scripts/sstate-cache-management.sh b/scripts/sstate-cache-management.sh
index 7d81daf..2d4a2a3 100755
--- a/scripts/sstate-cache-management.sh
+++ b/scripts/sstate-cache-management.sh
@@ -47,7 +47,9 @@ Options:
-d, --remove-duplicated
Remove the duplicated sstate cache files of one package, only
- the newest one will be kept.
+ the newest one will be kept. The duplicated sstate cache files
+ of one package must have the same arch, which means sstate cache
+ files with multiple archs are not considered duplicate.
Conflicts with --stamps-dir.
--
1.7.10.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/3] sstate-cache-management.sh: don't hardcode available sstate_suffixes
2013-02-26 7:57 [PATCH 0/3]sstate-cache-management.sh: fix remove duplicate failed when multiple archs Hongxu Jia
2013-02-26 7:57 ` [PATCH 1/3] sstate-cache-management.sh: " Hongxu Jia
@ 2013-02-26 7:57 ` Hongxu Jia
2013-02-26 7:57 ` [PATCH 3/3] sstate-cache-management.sh:fix the incorrect usage of option `-d' Hongxu Jia
2 siblings, 0 replies; 4+ messages in thread
From: Hongxu Jia @ 2013-02-26 7:57 UTC (permalink / raw)
To: openembedded-core
Don't hardcode available sstate_suffixes(it misses `packagedata'), find them
dynamically in $sstate_list.
[YOCTO #3635]
Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
---
scripts/sstate-cache-management.sh | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/scripts/sstate-cache-management.sh b/scripts/sstate-cache-management.sh
index 2d4a2a3..90e6764 100755
--- a/scripts/sstate-cache-management.sh
+++ b/scripts/sstate-cache-management.sh
@@ -185,11 +185,16 @@ remove_duplicated () {
| sed -e 's/-/_/g' -e 's/ /\n/g' | sort -u)
echo "Done"
- sstate_suffixes="deploy-rpm deploy-ipk deploy-deb deploy package populate-lic populate-sysroot"
-
# Save all the sstate files in a file
sstate_list=`mktemp` || exit 1
find $cache_dir -name 'sstate-*.tgz' >$sstate_list
+
+ echo -n "Figuring out the suffixes in the sstate cache dir ... "
+ sstate_suffixes="`sed 's/.*_\([^_]*\)\.tgz$/\1/g' $sstate_list | sort -u`"
+ echo "Done"
+ echo "The following suffixes have been found in the cache dir:"
+ echo $sstate_suffixes
+
echo -n "Figuring out the archs in the sstate cache dir ... "
for arch in $all_archs; do
grep -q "\-$arch-" $sstate_list
--
1.7.10.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 3/3] sstate-cache-management.sh:fix the incorrect usage of option `-d'
2013-02-26 7:57 [PATCH 0/3]sstate-cache-management.sh: fix remove duplicate failed when multiple archs Hongxu Jia
2013-02-26 7:57 ` [PATCH 1/3] sstate-cache-management.sh: " Hongxu Jia
2013-02-26 7:57 ` [PATCH 2/3] sstate-cache-management.sh: don't hardcode available sstate_suffixes Hongxu Jia
@ 2013-02-26 7:57 ` Hongxu Jia
2 siblings, 0 replies; 4+ messages in thread
From: Hongxu Jia @ 2013-02-26 7:57 UTC (permalink / raw)
To: openembedded-core
The description of option `-d' is not correct in useage. It is used to
remove duplicate and debug at the same time. Use option `-D' to control
debug info output and the option `-d' to flag remove duplicate.
[YOCTO #3635]
Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
---
scripts/sstate-cache-management.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/scripts/sstate-cache-management.sh b/scripts/sstate-cache-management.sh
index 90e6764..24384ef 100755
--- a/scripts/sstate-cache-management.sh
+++ b/scripts/sstate-cache-management.sh
@@ -72,7 +72,7 @@ Options:
-v, --verbose
explain what is being done
- -d, --debug
+ -D, --debug
show debug info, repeat for more debug info
EOF
@@ -393,7 +393,7 @@ while [ -n "$1" ]; do
verbose="-v"
shift
;;
- --debug)
+ --debug|-D)
debug=`expr $debug + 1`
echo "Debug level $debug"
shift
--
1.7.10.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-02-26 8:13 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-26 7:57 [PATCH 0/3]sstate-cache-management.sh: fix remove duplicate failed when multiple archs Hongxu Jia
2013-02-26 7:57 ` [PATCH 1/3] sstate-cache-management.sh: " Hongxu Jia
2013-02-26 7:57 ` [PATCH 2/3] sstate-cache-management.sh: don't hardcode available sstate_suffixes Hongxu Jia
2013-02-26 7:57 ` [PATCH 3/3] sstate-cache-management.sh:fix the incorrect usage of option `-d' Hongxu Jia
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox