3

A previous question, How do I find out which package owns a file? asked about Debian-based package management. I have the same question for SUSE Enterprise 10, using YaST (or any other tool suitable for the task).

I'm looking for something similar to apt-file or yum whatprovides.

2 Answers2

4

for rpm based distributions:

rpm -qf /path/to/file

returns package name-version-release.arch string

for example:

mimi@argusek ~  $ rpm -qf /usr/bin/aclocal
automake-1.15-4.6.noarch

and in SUSE based distributions:

zypper search -f string

while string is searched part of the filelist in package

mimi.vx
  • 255
1

For me this works:

Code:

# zypper se --file-list gl3.h
Loading repository data...
Reading installed packages...

S  | Name                 | Summary                                | Type
---+----------------------+----------------------------------------+--------
i+ | Mesa-libGLESv3-devel | Файлы разработки для API OpenGL ES 3.x | package

However all of the above does not work if package containing the file is not installed:

# zypper se --file-list --match-substrings gl3.h
Loading repository data...
Reading installed packages...
No matching items found.

So if file not listed in provides section then no way to find it until package installed.

Aleksey K
  • 177