Feature changed by: Tino K (tk52) Feature #308437, revision 6 Title: zypper search in package content openSUSE-11.3: Evaluation Priority Requester: Important Requested by: Michal Vyskocil (mvyskocil) Description: Zypper search should be extended to search also in a filelist of package, which can make webpin or package pin obsolete. zypper search --search-content gpm.h Will return all packages matching 'gpm.h' string in a filelist. Discussion: #1: Roberto Mannai (robermann79) (2009-12-01 19:00:10) webpin still would allow searching inside a not installed package #2: Tim Edwards (tk83) (2010-01-27 16:19:50) This feature is especially important when you're compiling software. For example today I was building something and gcc complained that glibconfig.h was missing. There was no way to find out which of the hundreds of -devel packages provided this file, except for guessing (it was in glib2-devel). Many header files are much more difficult to find than glib ones. In Mandriva, which has this feature (see http://wiki.mandriva.com/en/Tools/urpmi#urpmf), I could've just done: urpmf glibconfig.h and it would've said 'glib2-devel' + #3: Tino K (tk52) (2010-09-09 16:04:36) + Very important feature, very much needed! zypper wp provides some of + the functionality but is too crippled to be useful. For example + zypper wp libpng12.so # No providers of 'libpng12.so' found. + zypper wp libpng12.so.0 # finds libpng12-0 + zypper wp libpng12.so.0.39.0 # No providers of 'libpng12.so.0.39.0' + found. + + $ rpm -ql libpng12-0 + /usr/lib64/libpng12.so.0 + /usr/lib64/libpng12.so.0.39.0 + + $ rpm -ql libpng-devel | grep so + /usr/lib64/libpng.so + /usr/lib64/libpng12.so + + Even the man page is not quite correct as it says: + The NAME component of a capability is not only a package name but + any symbol provided by packages: /bin/vi, libcurl.so.3, + ... + + However we get: + zypper wp /bin/vim # No providers of '/bin/vim' found. + + I understand the reason for this behaviour is that zypper does not save + the entire file list of each rpm package (rpm -ql) in the repodata + directory but only what each package provides (rpm -q --provides). + $ rpm -q --provides libpng12-0 + libpng = 1.2.39-2.2 + libpng12.so.0()(64bit) + libpng12.so.0(PNG12_0)(64bit) + libpng12.so.0(libpng12.so.0)(64bit) + libpng12-0 = 1.2.39-2.2 + libpng12-0(x86-64) = 1.2.39-2.2 + $ rpm -q --provides libpng-devel + libpng-devel = 1.2.39-2.2 + libpng-devel(x86-64) = 1.2.39-2.2 + + I would very much recommend for zypper to save the entire file list + (rpm -ql) of each package in the repodata directory + /var/cache/zypp/raw/<repo name>/repodata/....xml.gz + That will inflate the file sizes quite a bit but that's just a small + price to pay for essential information. -- openSUSE Feature: https://features.opensuse.org/308437