add pkgcache_count() to api. sum it up
dump the pkgcache_count() result in testing