summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@windriver.com>2010-08-31 18:57:06 -0500
committerRichard Purdie <rpurdie@linux.intel.com>2010-09-02 10:01:22 +0100
commit379ba0e9d73a96f72982070a71532e035878fee0 (patch)
treebc9726a7d0ab128b1a90652a3c103924a5746ba4 /meta
parent84f7f70308eed0ac96abeb5a762e9b7765e5db91 (diff)
downloadpoky-379ba0e9d73a96f72982070a71532e035878fee0.tar.gz
rootfs_rpm: Optimize rpm database processing
Optimize the creation of the solverdb by disabling fsyncs and database caches that are not used when generating a solution. Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/package_rpm.bbclass4
-rw-r--r--meta/classes/rootfs_rpm.bbclass2
2 files changed, 5 insertions, 1 deletions
diff --git a/meta/classes/package_rpm.bbclass b/meta/classes/package_rpm.bbclass
index 36eb8e308b..89e8fe891a 100644
--- a/meta/classes/package_rpm.bbclass
+++ b/meta/classes/package_rpm.bbclass
@@ -36,6 +36,7 @@ package_update_index_rpm () {
36 cat /dev/null > ${DEPLOY_DIR_RPM}/solvedb.conf 36 cat /dev/null > ${DEPLOY_DIR_RPM}/solvedb.conf
37 for pkgdir in $packagedirs; do 37 for pkgdir in $packagedirs; do
38 if [ -e $pkgdir/ ]; then 38 if [ -e $pkgdir/ ]; then
39 echo "Generating solve db for $pkgdir..."
39 rm -rf $pkgdir/solvedb 40 rm -rf $pkgdir/solvedb
40 mkdir -p $pkgdir/solvedb 41 mkdir -p $pkgdir/solvedb
41 echo "# Dynamically generated solve manifest" >> $pkgdir/solvedb/manifest 42 echo "# Dynamically generated solve manifest" >> $pkgdir/solvedb/manifest
@@ -43,6 +44,9 @@ package_update_index_rpm () {
43 ${RPM} -i --replacepkgs --replacefiles --oldpackage \ 44 ${RPM} -i --replacepkgs --replacefiles --oldpackage \
44 -D "_dbpath $pkgdir/solvedb" --justdb \ 45 -D "_dbpath $pkgdir/solvedb" --justdb \
45 --noaid --nodeps --noorder --noscripts --notriggers --noparentdirs --nolinktos --stats \ 46 --noaid --nodeps --noorder --noscripts --notriggers --noparentdirs --nolinktos --stats \
47 --ignoresize --nosignature --nodigest \
48 -D "_dbi_tags_3 Packages:Name:Basenames:Providename:Nvra" \
49 -D "__dbi_cdb create mp_mmapsize=128Mb mp_size=1Mb nofsync" \
46 $pkgdir/solvedb/manifest 50 $pkgdir/solvedb/manifest
47 echo $pkgdir/solvedb >> ${DEPLOY_DIR_RPM}/solvedb.conf 51 echo $pkgdir/solvedb >> ${DEPLOY_DIR_RPM}/solvedb.conf
48 fi 52 fi
diff --git a/meta/classes/rootfs_rpm.bbclass b/meta/classes/rootfs_rpm.bbclass
index 9cbfdd3db3..f56acada7c 100644
--- a/meta/classes/rootfs_rpm.bbclass
+++ b/meta/classes/rootfs_rpm.bbclass
@@ -49,7 +49,7 @@ fakeroot rootfs_rpm_do_rootfs () {
49 for pkg in ${PACKAGE_INSTALL} ; do 49 for pkg in ${PACKAGE_INSTALL} ; do
50 echo "Processing $pkg..." 50 echo "Processing $pkg..."
51 for solve in `cat ${DEPLOY_DIR_RPM}/solvedb.conf`; do 51 for solve in `cat ${DEPLOY_DIR_RPM}/solvedb.conf`; do
52 pkg_name=$(${RPM} -D "_dbpath $solve" -q --yaml $pkg | grep -i 'Packageorigin' | cut -d : -f 2) 52 pkg_name=$(${RPM} -D "_dbpath $solve" -D "_dbi_tags_3 Packages:Name:Basenames:Providename:Nvra" -D "__dbi_cdb create mp_mmapsize=128Mb mp_size=1Mb nofsync" -q --yaml $pkg | grep -i 'Packageorigin' | cut -d : -f 2)
53 if [ -n "$pkg_name" ]; then 53 if [ -n "$pkg_name" ]; then
54 break; 54 break;
55 fi 55 fi